iOS has three multithreaded technologies:
1.NSThread
Created in two ways:
1. Instance method:
-(ID) Initwithtarget: (ID) Target selector: (SEL) Selector object: (ID) argument
You can set thread
In the daily coding process, we almost developed the habit of using ID for all the return values of the indeterminate type. Indeed, Because it has a general-purpose pointer feature of the balm, plus instancetype after ios7.0. Many people have not
Cggeometry reference defines geometry and functionality for easy operation. A point cgpoint in the data structure is represented in a two-dimensional coordinate system. The location and size of the data structure CGRect represents a rectangle. The
How to master a high-level programming language:(here specifically objective-c)bottom-up thinking: down, how to think about the process of running the program from the bottom of the machine. Focus on language constructs, compilation transformations,
Two classes are provided in objective-c to implement dictionaries, namely nsdictionary and nsmutabledictionary. Among them, Nsmutabledictionary is a subclass of Nsdictionary, which inherits the parent class method while supporting the insertion and
Hello, I am kellybaby. Today we are going to introduce objective-c language.Friends around the classmate said, I give them to explain the things are always very vernacular, easy to understand, I hope that this vernacular programming language to
Starting today with OC Write iOS program, encountered problems have1. When different classes use the method of a class or access the properties of a class (public methods or properties), the method or property must be declared in the class header
Block type
Block is a data type that is widely used in iOS development and is highly recommended by Apple, which functions like a function pointer in C.^ is a unique symbol of block.The implementation code for the block is included in the {}.In
GitHub's Objective-c animated UI library is actually the most part, and GitHub has quite a part of the animated Daniel, such as Jonathan George,nick Lockwood,kevin,roman Efimov,christopher Wendel,jared Verdi,peter Steinberger, and so on, are some
Use of KVC
1, KVC full name key valued coding key value codeThe reflection mechanism is in the running state, for any class, can know all the properties and methods of this class, for any one object, can call any of its methods and properties.
Let's talk about what we'll mention in this article: ##,__va_args__, __file__, __line__, __function__, etc.Macro variables:To give an example, you'll use these macros: #define myprintf (...) printk ("[Lch]:file:%s, line:%d, function:%s," \
Uinavigationcontroller (Navigation view Controller)The Navigation view Controller is also a view controller that manages multiple child view controllers, and when you use the Navigation view controller for layout, you need to specify the window's
Today learned a bit Uilabel Uitextfield UIButton uiimage These basic controls, uilabel nothing to say, because do not involve the exchange of work, remember a few properties on the line.Uitextfield this thing, encountered a lot of problems. I use
1, Nsset1. is an unordered collection class that manages multiple objects, with the greatest feature being that duplicate objects are not allowed in the collection, and that the mathematical set meanings are the same2. Other functions and Nsarray
Nslog is similar to printf and will also output the display result on the console.
% @ Object
• % D, % I integer
• % U unsigned integer
% F floating point/double-Character
% X, % x binary integer
% O octal integer
• % Zu size_t
• % P
Difficult to express original meaning in Chinese
Method and class attributes
Objective-CNow supports some GCC attributes for objective-C methods.Syntactically, attributes for a method follow the method's declaration,And attributes for a method
Zproperty declaration attribute DeclarationSpecifying the attribute (attributes) for instance variables allows the compiler to generate methods for accessing instance variables without leakage and thread security.
Property)
@property (copy,
In addition to using objective-C on a Mac system, it is also possible to download and install the gnustep and objective-C environments for Microsoft's Windows family of operating systems. in this chapter we will release e the steps involved in
The blocks in OC is similar to the function pointer in C ++. It can be seen from the appearance and usage.
INT (* cfunc) (int A); // function pointer in C language. Call intret = (cfunc) (10 );
INT (^ bfunc) (int A); // BlocksCall intret = (bfunc) (
Introduction to the objective-C Programming Language
Introduction to object-oriented C language programming:
Object-oriented C language is a simple computer language designed for advanced object-oriented programming. The object-oriented C language
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