Introduction to Java-objects

Source: Internet
Author: User

basic features of object-oriented languages:
1. All things are objects.
2. Programs are collections of objects that tell each other what they want to do by sending messages.
3. Each object is its own storage composed of other objects.
4. Each object has its type.
5. All objects of a particular type can receive the same message.

Access qualifier for Java: Public, private, protected. an Access qualifier is not set to a package access permission.
C + + is not dynamically bound by default (add virtual), Java by default, more inclined to object-oriented.
Upward Transformation (polymorphic invocation), downward transition (container retrieve object-parameterized type)
Java Dynamic memory allocation: All objects are inherited from a single-rooted class object and can only be created on the heap.
such as: string s = new String ("123"); s in the stack, the object "123" is in the heap, S points to "123".
Concurrent programming: Java built-in, shared resources: A task locks a resource, completes its tasks, and then releases the resource lock so that other tasks can use the resource.

Object-oriented : The object that is used to represent the problem space, and the message that is sent to these objects to represent the behavior within this space.

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

Introduction to Java-objects

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.