Object-Oriented programming (summary of this chapter)

Source: Internet
Author: User
Tags define abstract
1. Object-oriented has 3 main features, which are encapsulated. Succession, polymorphism.


2, suppose a drug is set to inherit must specify Notfinal, this class cannot be inherited or.




3, if you want to check out the data to sort, you can use map or order to define the function.




4. In a class. The construction method provided by default requires that all property content be passed. Assuming that the user has the need, you can also use constructor to define the constructor that defines the parameters.




5, in object-oriented. The ability to instantiate a parent class through a subclass so that the functions called by each parent class object implement different functions depending on the subclass of the function that is being covered.


6, you can use not instantiable to define abstract functions in a class. The class in which the abstract function resides is called an abstract class, which is inherited by subclasses using overriding for function override.


7. The ability to create a data table from a specified class. The fields in this table are the properties in the class.


8, through the object view, the data table can be returned directly in the form of the class object.

Copyright notice: This article blog original articles, blogs, without consent, may not be reproduced.

Object-Oriented programming (summary of this chapter)

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.