PHP Learning notes PHP object-oriented Programming _php Foundation

Source: Internet
Author: User
Copy code code as follows:

<?php
/* PHP object-oriented programming
*
* PHP5
*
* Arrays and objects: A composite type of PHP (a variable can store multiple units)
*
* Objects are more powerful than arrays, not only can you store multiple data, you can also include functions in objects
*
* Three main characteristics of the object: encapsulation, inheritance, polymorphism
*
* object-oriented Programming (OOP)//conforming to reusability flexibility extensibility in software engineering
*
* The difference between object-oriented and process-oriented
*
* Minimum unit: function//Process oriented
* Smallest Unit: Object//Object oriented
*
* What is an object
Recently, Sina Management began to set up now, public information disclosure, that year's MBO made management high-spirited to become Sina's largest shareholder, but today, they have become the second largest shareholder. The equity ratio is small: the ratio of fmr9.24% to the largest shareholder is only 0.1%. But Sina's management has agreed to sell the stakes, and if the stakes are to be sold in the future, the management will have only 5.74% left. Sina is indeed likely to become a "unowned company" again.
This is Sina as a company, the future of trouble: The profit model is not clear, the possibility of the owner began to show.
* object is an entity
Object
* member Property = = variable//define the appearance and status of the object
* member Method = = function//define the function of the object
*
* What is a class
* classification, type, custom type
*
* Define the properties and methods of this type in the class
*
* A relationship between a class and an object
*
* Declaring class--> instantiating objects (creating objects)--> using objects
*
*
* The most difficult thing is how to design object-oriented programs, not object-oriented syntax.
*
*/
?>

Author: symbol Aurora
Source: http://zizhuyuan.cnblogs.com

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.