Declare a class as an atribute of another class in Java -


how define class attribute of class? can have multiple classes of classes, class an attribute of class users?

class community{   class users();   static string x;   static int y;   community(){} } class users{   static string name;   static int reputation; } 

in java there nested classes , mean can create class inside class , :

    class x{ class y{ } y newy=new y(); } 

and here newy object or member inside class x


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -