Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
Can you declare a class as private?
Can you declare a class as private?
✍: Guest
Yes, we can declare a private
class as an inner class. For example,
class MyPrivate {
private static class MyKey {
String key = "12345";
}
public static void main(String[] args) {
System.out.println(new MyKey().key);//prints 12345
}
}
2012-08-23, 2739👍, 0💬
Popular Posts:
Why is there extra white space before or after tables? This is often caused by invalid HTML syntax. ...
How To Compile a JUnit Test Class? Compiling a JUnit test class is like compiling any other Java cla...
How do we access attributes using “XmlReader”? Below snippets shows the way to access attributes. Fi...
Can static variables be declared in a header file? You can't declare a static variable without defin...
Can Two Forms Be Nested? - XHTML 1.0 Tutorials - Understanding Forms and Input Fields Can two forms ...