当前位置:网站首页>[nature of class (in Objective-C language)]
[nature of class (in Objective-C language)]
2022-07-28 03:15:00 【Breezy morning】
Preface
stay Objective-C In language , What is the nature of class ?
One 、 What are the five areas of memory ?
1. Stack —— Store local variables
2. Pile up —— For storage programmers malloc,realloc,calloc The space you applied for , And class objects .
3.BSS paragraph —— Store uninitialized global variables , Static variables
4. Data segment ( The constant area )—— Store initialized global variables , Static variables .
5. Code segment —— Binary code of storage class , Method binary code
Two 、 The essence of class
1. When is the class loaded into the code segment ?
When the class is first accessed , Is loaded into the code segment , be called “ Class loading ”.
2. Once the class is loaded into the code segment , When to recycle ?
Recycle at the end of the program .
3. In what form are classes stored in code segments ?
1) Preface : Any data stored in memory , There's a data type .
2) Preface : Any space requested in memory , There are also their own types .
3) What kind of space is there to store classes in code snippets :Class Type of
4) Steps to store classes in code snippets :
a. Now create a Class object .
b. Class yes Foundation A class in the framework , that Class What is the object , Is used to store classes .
c. Store the class information in this Class Among objects
d. This Class An object should have at least three properties :
- ClassName Storage class name
- Storage class properties
- Methods of storing classes
e. remember , This is an object , So there's one in it iSA The pointer , This pointer points to the parent class of this class .
summary
This article describes the nature of classes , Then we will add how to get this class object , And how to call class methods through class objects .
边栏推荐
- Comprehensive case
- Kubernetes -- Introduction
- Oracle basicfile lob field space recycling shrink space doubts
- Qt官方示例:Fridge Magnets Example(冰箱贴)
- ELS timer
- R 笔记 MICE
- 小程序已获取数据库合集中的总记录、用户位置,怎么用Aggregate.geoNear将经纬度由近到远排列?
- JVM 内存布局详解,图文并茂,写得太好了!
- Data Lake: each module component
- Scheme sharing | experts gather to jointly explore accent AI speech recognition
猜你喜欢

QFileDevice、QFile、QSaveFile、QTemporaryFile

四、固态硬盘存储技术的分析(论文)

Exness: Japanese prices rose and incomes fell, with the pound / yen breaking 165

4、 Analysis of solid state disk storage technology (paper)

42.js -- precompiled

R 笔记 MICE

Design of the multi live architecture in different places of the king glory mall

Web服务器

MySQL索引学习

Record of a cross domain problem
随机推荐
C#设置Textbox控件不可编辑
C#中关闭窗体的四种方法
Tungsten Fabric SDN — BGP as a Service
嵌入式分享合集22
QML使用Layout布局时出现大量<Unknown File>: QML QQuickLayoutAttached: Binding loop detected for property循环绑定警告
Full of dry goods, hurry in!!! Easy to master functions in C language
Intelligent industrial design software company Tianfu C round financing of hundreds of millions of yuan
机器人工程是否有红利期
Uniapp——拨打电话、发送短信
Record of a cross domain problem
Alibaba cloud international email service package purchase process
Interview experience: first tier cities move bricks and face software testing posts. 5000 is enough
Original title of Blue Bridge Cup
Comprehensive case
数据湖:各模块组件
谈一谈百度 科大讯飞 云知声的语音合成功能
蓝桥杯:第九届—“彩灯控制器”
exness:日本物价上涨收入下降,英镑/日元突破 165
RBD块存储设备的扩容以及缩容操作(六)
工程电磁场复习基本知识点