Learning notes on special member variables in C + + classes
It is said that the roommate static member variable does not know its role, and it is also said that the roommate const is not very good. I wrote this study note with my backhand. The data members in a class not only have int s and char s, but also describe many complex situations. The data members in a class may need to be shared among multipl ...
Posted by TheHeretic on Wed, 24 Nov 2021 05:29:06 -0800
A thorough understanding of Python object-oriented programming
Before I started, I had been trying to find a popular and intuitive example to introduce object-oriented. Look around and find that everything can be object-oriented and nothing is object-oriented. Later, I found that the way human beings understand society is more object-oriented. "Birds of a feather flock together and people flock togeth ...
Posted by dylan001 on Mon, 22 Nov 2021 07:17:06 -0800
[Java] object oriented -- understanding of interfaces
An interface is a further step of an abstract class. An abstract class can also contain non abstract methods and fields. While the methods contained in an interface are abstract methods, and fields can only contain static constants
Sometimes you must derive a subclass from several classes and inherit all their properties and meth ...
Posted by pinxue on Sat, 20 Nov 2021 22:32:38 -0800
C + + learning notes
This blog is derived from C + + language learning. Constructors are widely used. Constructors generally need 1. The constructor name is the same as the class name; 2. There is no return value type declaration before the constructor name. 3. Constructor cannot return a value through return. 4. Typically, constructors have a public attribute. The ...
Posted by kovudalion on Sat, 20 Nov 2021 09:50:45 -0800
javaScript learning notes 18 days -- object-oriented pattern
When you need to get a certain type of object in large quantities, you can use factory mode
Factory mode
Steps:
Create a functionReturns an object in the function return {} //Create factory function
//1. Create function and object attributes
function createPerson(name,age,address,className){
//2. Return th ...
Posted by jtp51 on Wed, 17 Nov 2021 05:25:19 -0800
Class (another day when I don't know what to take)
Tip: the following is the main content of this article. The following cases can be used for reference
1, Date class (time date class)
1. General
Date represents a specific time, accurate to milliseconds
2. Construction method
Method nameexplainpublic Date()Allocate a Date object and initialize it so that it represents the time it is ...
Posted by Andy-H on Thu, 28 Oct 2021 19:58:26 -0700
Three characteristics of object oriented
preface
This article introduces the three characteristics of object-oriented.
Tip: the following is the main content of this article. The following cases can be used for reference
1, Encapsulation
1. Concept
It is one of the three characteristics of object-oriented (encapsulation, inheritance and polymorphism). It is the simulation ...
Posted by xengvang on Tue, 26 Oct 2021 04:31:57 -0700
PlantUML Quick Start UML Time Series Diagram
UML Sequence Diagram
Sequence diagrams are the most commonly used UML diagrams after class diagrams. Sequence diagrams represent interactions as a two-dimensional graph with the time axis vertically and the time going down vertically. The horizontal axis represents the roles in collaboration and is generally a Class.Objects, with a dashed line ...
Posted by zrueda on Tue, 12 Oct 2021 10:08:11 -0700
Object oriented python
object
1. An object is a concrete existence created by a class and can be used directly 2. The object created by which class has the properties and methods defined in which class 3. The object is relative to the aircraft manufactured by the application drawing, and the drawing is a class 4. In development, there should be classes first and the ...
Posted by Dave3765 on Sun, 10 Oct 2021 00:09:35 -0700
JAVA foundation [day12]: exception
I can't do too many things in my life, so everything should be wonderful-------- Steve Jobs
abnormal
(1) Abnormal conditions in the program. (2) Abnormal system Throwable |– Error is a serious problem and we won't deal with it. |–Exception |– RuntimeException is a runtime exception. We need to correct the code |– non ...
Posted by AliasXNeo on Sat, 09 Oct 2021 02:51:24 -0700