question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Inner-Class Component Generated Code Naming

See original GitHub issue
public class Foo {
  @Component
  public class Bar {}
}

produces Dagger_Foo$Bar. AutoValue produces names in the form Dagger_Foo_Bar which seems much more desirable.

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Comments:17

github_iconTop GitHub Comments

2reactions
cgrubercommented, Apr 16, 2015

Dagger 2.0 has been released, and the names are, for @Component Foo you get DaggerFoo, and for @Component Bar.Blah (nested) you get DaggerBar_Blah as the implementation types for components.

On Mon, 13 Apr 2015 at 10:41 TJ (Thomas J.) Biddle notifications@github.com wrote:

@cgruber https://github.com/cgruber Also - quick clarification. This will also fix the issue regarding the prefixes having changed from the 2.0-SNAPSHOT? They used to be Dagger_xxxx And now it’s just Daggerxxxx from what I’m hearing

— Reply to this email directly or view it on GitHub https://github.com/google/dagger/issues/58#issuecomment-92442139.

0reactions
cgrubercommented, Apr 8, 2015

Fixed in #150

Read more comments on GitHub >

github_iconTop Results From Across the Web

Inner Classes - Learning Java [Book] - O'Reilly
Inner classes rely on code generation; they are a feature of the Java language, but not of the Java virtual machine. As a...
Read more >
Java inner class and static nested class - Stack Overflow
A nested class is a class which is contained in another class at the source code level. It is static if you declare...
Read more >
Javanotes 9, Section 5.8 -- Nested Classes
From outside the containing class, however, an inner class has to be referred to using a name of the form variableName.
Read more >
Inner Classes Specification - Java Community Process
The code of an inner class can use simple names from enclosing scopes, including both class and instance members of enclosing classes, and...
Read more >
Nested Classes - Learning the Java Language
It can lead to more readable and maintainable code: Nesting small classes within top-level classes places the code closer to where it is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found