Basic Structure of a Java Class

Basic Structure of a Java Class

Previous Home Next

 

java class consists the methods and the data .


 


 
 class A   // final class declaration all its methods are final
{
private int type; //field declaration
public int getType() //method declaration
{
return type;
}
}


Previous Home Next