Replace
Super.Sub rr = new Super.Sub();
with
Super.Sub rr = new Super().new Sub();
or declare Sub
as static class
.
Check this to learn more about it.
More Related Contents:
- How to format java.util.Date with DateTimeFormatter portable?
- How to create Canvas object by calling Canvas constructor with arguments in Java?
- Unfortunately MyApp has stopped. How can I solve this?
- Why can’t I use switch statement on a String?
- Received fatal alert: handshake_failure through SSLHandshakeException
- What is the “Execute Around” idiom?
- How to set the environment variables for Java in Windows
- What is the maximum depth of the java call stack?
- Getting a ConcurrentModificationException thrown when removing an element from a java.util.List during list iteration? [duplicate]
- How to write console output to a txt file
- Dynamic Graphics Object Painting
- Change background color of single specific menu items of navigationView
- Java 8 Instant.now() with nanosecond resolution?
- Java JTextField with input hint
- Convert hex string to int
- In a switch statement, why are all the cases being executed?
- I would like to set my variables at the top of my class instead of in the method
- How to set AUTO-SCROLLING of JTextArea in Java GUI?
- How to wait until an element is present in Selenium?
- What is the difference between an ordered and a sorted collection?
- How can I include test classes into Maven jar and execute them?
- JPA – Returning an auto generated id after persist()
- Julian day of the year in Java
- How to access nested elements of json object using getJSONArray method
- What is the correct way to do inserts/updates/deletes in Android SQLiteDatabase using a query string?
- Java Swing – Using JScrollPane and Having it scroll back to top
- Java NIO: What does IOException: Broken pipe mean? [duplicate]
- Difference between SparkContext, JavaSparkContext, SQLContext, and SparkSession?
- Table like java data structure
- SLF4J + Logback does not log in WildFly