Coding Guidelines for Cocoa
Introduction to Coding Guidelines for Cocoa 7 Organization of This Document 7 Code Naming Basics 9 General Principles 9 Prefixes 10 Typographic Conventions 11 Class and Protocol Names 11 Header Files 12 Naming Methods 13 General Rules 13 Accessor Methods 14 Delegate Methods 15 Collection Methods Method Arguments Private Methods 18 16 17 Naming Functions 19 Naming Instance Variables and Data Types 21 Instance Variables 21 Constants 21 Enumerated constants 21 Constants created with const 22 Other types of constants 22 Exceptions and Notifications 22 Exceptions 23 Notifications 23 Acceptable Abbreviations and Acronyms 25 Tips and Techniques for Framework Developers 27 Initialization 27 Class Initialization 27 Designated Initializers 27 Error Detection During Initialization 28 2006-04-04 | © 2003, 2006 Apple Computer, Inc. All Rights Reserved. 3 4 Versioning and Compatibility 28 Framework Version 29 Keyed Archiving 29 Object Sizes and Reserved Fields 30 Exceptions and Errors 30 Framework Data 31 Constant Data 31 Bitfields 32 Memory Allocation 32 Language Issues 33 Messaging nil 33 Object Comparison 33 Protocols 33 Autoreleasing Objects 34 Accessor Methods 34 Document Revision History 37




剩余37页未读,继续阅读














- 粉丝: 188
- 资源: 452
我的内容管理 收起
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助

会员权益专享

评论0