Objective-C Compiler Directives

@dynamic

"You use the @dynamic keyword to tell the compiler that you will fulfill the API contract implied by a property

either by providing method implementations directly or at runtime using other mechanisms such as dynamic

loading of code or dynamic method resolution. " R[0]p61

 

"@dynamic just tells the compiler that the getter and setter methods are implemented not by the class itself

but somewhere else (like the superclass or will be provided at runtime)."  Ref[4]

"Tells the compiler the setter and getter methods for the given (comma separated) properties are implemented manually,

or dynamically at runtime. Accessing a dynamic property will not generate a compiler warning, even if the getter/setter

is not implemented. You will want to use @dynamic in cases where property getter and setter methods perform custom code.

@end – Marks end of class implementation." Ref[8]

@synthesize

"Generate setter and getter methods for a comma separated property list according to property modifiers.

If instance variable is not named exactly like @property, you can specify instance variable name after the equals sign." Ref[8]

__attribute__

iOS.ObjC.__attribute__-directives


Reference

0. Objective-C 2.0 Programming Language

1. http://www.learn-cocos2d.com/2011/10/complete-list-objectivec-20-compiler-directives/

2. http://stackoverflow.com/questions/4621952/what-does-dynamic-do-in-objective-c

3. http://www.meonbinary.com/2013/05/objective-c-associated-objects

4. Objective-C: @synthesize vs @dynamic

http://ios-blog.co.uk/tutorials/objective-c/synthesize-vs-dynamic/

5. @dynamic vs @synthesize (To Read)

http://andiputra7.tumblr.com/post/16822250097/dynamic-vs-synthesize

6. When should I use @synthesize explicitly?

https://stackoverflow.com/questions/19784454/when-should-i-use-synthesize-explicitly

7. @synthesize keyword explanation

https://forums.developer.apple.com/thread/69075

8. Objective-C @Compiler Directives

https://kapeli.com/cheat_sheets/Objective-C_@Compiler_Directives.docset/Contents/Resources/Documents/index

9. @

http://nshipster.com/at-compiler-directives/

iOS.ObjC.Compiler.Directives的更多相关文章

  1. iOS.ObjC.__attribute__-directives

    __attribute__ Directives Reference 1. __attribute__ directives in Objective-C (AAAA+) (Read Again) h ...

  2. iOS.ObjC.Basic-Knowledge

    1. ObjC的基础 2. ObjC2.0中的编译指令 3. ObjC Runtime 4. ObjC Object Model 5. ObjC的新语法 6. FQA 1. ObjC的基础 2. Ob ...

  3. iOS Objc Runtime 教程+实例Demo

    样例Demo 欢迎给我star!我会继续分享的. 概述 Objc Runtime使得C具有了面向对象能力,在程序执行时创建,检查.改动类.对象和它们的方法.Runtime是C和汇编编写的,这里http ...

  4. IOS obj-c、c、c++混编

    今天发现这个问题,上网找了一下资料,发现原来如下: .m 文件可以混合c 和 objective-c 代码 .mm  文件可以混合 c c++ objective-c 代码 .c  .cpp  不能混 ...

  5. [Draft]iOS.ObjC.Pattern.Builder-Pattern

    Builder Pattern in Objective-C Reference 1. The Builder pattern in Objective-C Published on 04 Apr 2 ...

  6. iOS入门及ObjC语法

    iOS入门:http://www.jonathanhui.com/ios ObjC语法: http://www.jonathanhui.com/objective-c https://github.c ...

  7. ios资源

    ios 资源 分类: ios开发2012-05-30 16:39 573人阅读 评论(0) 收藏 举报 ios文档calendar2010reference图像处理 学习过程当中查找到的资料,做一个记 ...

  8. 【转】IOS开发资源汇总

    转自:http://blog.csdn.net/favormm/article/details/6664970 如何用Facebook graphic api上传视频: http://develope ...

  9. Android&iOS崩溃堆栈上报

    Android&iOS崩溃堆栈上报 原文地址:http://www.cnblogs.com/songcf/p/4885468.html 通过崩溃捕获和收集,可以收集到已发布应用(游戏)的异常, ...

随机推荐

  1. web基础 (一) http协议

    一.什么是web服务 浏览器与网页服务端发起的请求与回应(返回的是一堆字符串,浏览器去渲染生成页面!)都是 标准的CS模式 ---- bs模式:客户端用浏览器即可,服务端需要自己去写 http协议是建 ...

  2. JQ树插件 — zTree笔记

    1.zTree作者很贴心的为使用者将不同功能的代码封装成不同的文件,方便大家尽量减少加载的代码量,如果基本全用到,则不必一个个引用,有一个文件“jquery.ztree.all.js”,包含了所有.如 ...

  3. 关系型数据库之Mysql

    简介 主要知识点包括:能够与mysql建立连接,创建数据库.表,分别从图形界面与脚本界面两个方面讲解 相关的知识点包括:E-R关系模型,数据库的3范式,mysql中数据字段的类型,字段约束 数据库的操 ...

  4. 【转】ECharts3.x中的点击事件与行为

    在ECharts中主要通过 on 方法添加事件处理函数,ECharts中的事件主要分为两种,1)鼠标事件,在鼠标click  or  hove 时触发鼠标事件: 2)另外一种是在ECharts在做图形 ...

  5. HTML 标签说明

    标签 描述 <!--...--> 定义注释. <!DOCTYPE>  定义文档类型. <a> 定义锚. <abbr> 定义缩写. <acronym ...

  6. spring data jpa分页5种方法

    7.12.12 分页 本地sql查询 注意表名啥的都用数据库中的名称, 适用于特定数据库的查询 public interface UserRepository extends JpaRepositor ...

  7. 在 WampServer 上手工安装 PHP 的多个版本

    手工安装新版本的PHP,只需以下步骤: 下载要安装的PHP版本.既然是用WampServer,那当然是下载Window版本的ZIP包啦:http://windows.php.net.解压到 Wamp的 ...

  8. html的基本数据类型(数字,字符串, 列表, 字典)

    基本数据类型 1. 数字 a = 18 ; 2. 字符串 a = 'alex'a.chartAt(索引位置)a.substring(起始位置, 借宿位置)a.length 获取当前字符串长度a.tri ...

  9. hibernate 三种状态

    JPA是Java Persistence API的简称,中文名Java持久层API. 因JPA是由Hibernate的创建者编写,因此和Hibernate基本相似一致.JPA由不同的服务解析,因此在w ...

  10. 4 python内置函数

    1.内置函数的整体介绍 内置参数官方详解 https://docs.python.org/3/library/functions.html?highlight=built#ascii 2.各内置函数介 ...