Why getCountStudent() method is called using Class Name instead of first making new
Virtual Position Forum :: Members Lounge :: Sciences & Knowledge :: Programing and Design :: Java Forum
Page 1 of 1 • Share
Why getCountStudent() method is called using Class Name instead of first making new
Why getCountStudent() method is called using Class Name instead of first making new object of class and then calling getCoubtStudent() method using that object??? Please sir explain it.
sharmila farooqi- Monstars
- Posts : 35
Join date : 2011-05-29
Re: Why getCountStudent() method is called using Class Name instead of first making new
The static data members and methods are associated with class and are not tied to any object. There will be only single copy of static data member inside a class. The static data members are shared by all the objects of class. The static method getCountStudent() can be accessed by class as well as object of the class.
Vuhelper- Deep Bench
- Posts : 97
Join date : 2011-05-29
Similar topics
» Notepad Class 4(Last Class)
» What does constructor do in class?Why we use copy constructor in class. Is it necessa
» The study method
» Why we are passing IndexOutOfBoundsException ex in catch?we have not ex.any Method or
» US should restrain from making accusations against Pak: Hoti
» What does constructor do in class?Why we use copy constructor in class. Is it necessa
» The study method
» Why we are passing IndexOutOfBoundsException ex in catch?we have not ex.any Method or
» US should restrain from making accusations against Pak: Hoti
Virtual Position Forum :: Members Lounge :: Sciences & Knowledge :: Programing and Design :: Java Forum
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
Yesterday at 10:16 pm by ali001
» Amuse - Become Smarter
Wed May 15, 2024 10:50 am by ali001
» Fort Lock
Sat May 04, 2024 11:49 am by ali001
» house disrepair claims
Thu May 02, 2024 4:29 pm by Ibad Khan Buledi
» Bounce n Bang: Physics puzzler
Thu May 02, 2024 11:39 am by ali001
» AIChatSY - AIChatbot Assistant
Wed May 01, 2024 10:48 am by ali001
» Storybook Magic App
Tue Apr 30, 2024 7:06 pm by ali001
» Flower Book Match3 Puzzle Game
Tue Apr 30, 2024 12:17 pm by ali001
» Avian Influenza Symptom in Chickens "Bird Flu H5N1 Virus" Vet learning materials, Poultry Farming
Sat Apr 27, 2024 9:57 am by Ibad Khan Buledi