classes in java

When we declare a class in java,why does it automatically extends to object class? please let me know your views.

Replies

  • Morningdot Hablu
    Morningdot Hablu
    Object class is the super class of all the classes provided by java.lang package.
    And i think you know that all the basic functions to write a program like println() are the content of the classes provided by java.lang.
    I think this may be the reason that it will automaticully extend the object class(need not to extend the object class).
    Because you must have to write the basic functions to write any program in java.It's only for reducing time to write any program nothing else.
    .
    I am not 100% may be i am wrong on some point.
    Correct me if i am wrong.
  • sushant005
    sushant005
    What mohit explained is i think correct,
    In general programming concept we are generally using println() like methods which are member of Object class.These are the basic methods we are frequently using in our programs to print the statement.So i think thats reason why it is automatically extend to Object class.
  • anandkumarjha
    anandkumarjha
    thankyou sushant i got what you want to say
  • anandkumarjha
    anandkumarjha
    hi every one
    today while going through one java book i found that class in java is the templets of objects and objects are the instance of class. can any one explain what it wants to convey?
  • sushant005
    sushant005
    anandkumarjha
    hi every one
    today while going through one java book i found that class in java is the templets of objects and objects are the instance of class. can any one explain what it wants to convey?
    Ya, you are very correct that class is the template of object it means that class is a blueprint of an object.Like blue print means the description of items used to make objects, same as class is the combination of different items like methods, data members,fields,events.I mean to say that class defines the structure and behavior for an object.
    And object is an instance of class means that it gives the proper definition to the class.
    Without object class has not existence.
  • anandkumarjha
    anandkumarjha
    hello sushant
    I got what you shared with me but some times we find that class can be executed without an object like in simple java program?
  • sushant005
    sushant005
    anandkumarjha
    hello sushant
    I got what you shared with me but some times we find that class can be executed without an object like in simple java program?
    You are absolutely true, that is the reason why we use static in main method.By using static before the main method enable it to execute without creating the object of class.
  • anandkumarjha
    anandkumarjha
    Hello sushant
    just now i was going through ur blogs about touch screens. i could understand about the resistivity touch screen but could not understand about conductive. can you please make me understand?
  • sushant005
    sushant005
    anandkumarjha
    Hello sushant
    just now i was going through ur blogs about touch screens. i could understand about the resistivity touch screen but could not understand about conductive. can you please make me understand?
    its capacitive not conductive.
    In Capacitive TS(Touch Screen) the top layer is glass which makes it more resistant then resistive TS. Here the concept of capacitors is used. In capacitor two conductors are separated by an insulator.
    It is of two type:-
    1>Surface Capacitive and
    2>Projected capacitive.

    In Surface capacitive screen,the glass is coated with a conductive layer i.e Indium Tin oxide.
    So the complete structure of Surface Capacitive the glass is coated with conductive layer(Indium Tin Oxide) on its under side .

    Its working is that a small amount of voltage is applied to uniformly charge the entire surface and there is four electrode placed at each corner of the screen to check for any voltage changes.It means that when a conducting object or human finger touches the the charge is and then the voltage change is registered, all the four electrode detects this change and finally we got the central point of contact.

    In Projected Capacitive screen there are two parallel layers of conducting material(Indium Tin Oxide) But these layers are not flexible because both the layers are glass here if the human finger comes on contact with the screen then it causes a discharge and resultant voltage change is picked by the electrodes.
    This type of technology is used in iPhone and many smartphones.

    The main concept is that electrodes are placed such that they detect the voltage change when an conduction material touches the screen...

You are reading an archived discussion.

Related Posts

Independence day is coming So why not show our love towards our country by writing a poem You have to write a poem that would show your love towards your...
:smile:hi any one mail me some good project report for final year BE E.C. MY MAIL is
ThoughtWorks Studios is delighted to introduce Agile Varsity, an intensive 3-day workshop for the Agile team. These hands-on sessions, a combination of Agile Fundamentals and engineering practices, aim at getting...
how to convert RF signal to DC(constt) signal 😁😁 BIG K pls help me its urgent
i need some help for file compression, actually we are having project in c, so may i get the algorithm of file compression in c....plz help...