[Code Note] iOS-mobile phone system version, code note ios-version
I. Code.
-(Void) viewDidLoad {[super viewDidLoad]; // Do any additional setup after loading the view, typically from a nib. // mobile phone system version NSString * phoneVersion = [[UIDevice currentDevice] systemVersion]; NSLog (@ "-- mobile phone system version -- % @ -----", phoneVersion ); // mobile phone model NSDictionary * infoDicti
Js object-oriented learning note (cookie used with get parameters of url), Learning note cookie1. Use of cookies
2. get the get parameter of the url address
[Code Note] Get the date of the current week, the date of the Code note
I. Code.
-(Void) viewDidLoad {[super viewDidLoad]; // Do any additional setup after loading the view, typically from a nib. NSLog (@ "current week: % @", [self getWeekFromLocal]);} # pragma-mark-functions // obtain the date of the current week. format: wednesday-(NSString *) getWeekFromLocal {NSDate * senddate = [NSDate date]; NSDateF
[IOS] File Download Note, ios note
File downloads are dividedNSURLConnectionAndNSURLSessionTwo types, the former has a long history of hate. It is relatively difficult to use. The latter is new and some additional features are added.
1. Download NSURLConnection
TIPS:
1. When NSURLConnection is downloaded and NSData is written to a file, data does not occupy much memory. (even if the file is large) 2. A litt
[Code Note] process an image into a circle, and the code note into a circle
I ,.
2. Engineering Drawing.
3. Code.
ViewController. m
-(Void) viewDidLoad {[super viewDidLoad]; // Do any additional setup after loading the view, typically from a nib. // initialization interface [self addView];} # pragma-mark-functions // initialization interface-(void) addView {UIImageView * imageView = [[UIImageView alloc] i
[Code Note] detects mobile phone flip and code note flip
I. Code.
-(Void) viewDidLoad {[super viewDidLoad]; // Do any additional setup after loading the view. // listen to the mobile phone direction change event [[NSNotificationCenter defacenter center] addObserver: self selector: @ selector (orientationChanged) name: UIDeviceOrientationDidChangeNotification object: nil];} # pragma-mark-functions // process
Js basic note and js note
Three-scope chain
1. the variables defined in the function are local variables and the layer of the scope chain. The scope chain is searched from the inside out. If it is found, the search is stopped.
2. It does not have its own block-level scope (it refers to the block of code closed by curly brackets), such as the if for statement.
3. variables declared without the keyword va
[Code Note] Click anywhere, and the city appears. Click city in the Code note.
I ,.
2. project directory.
3. Code.
// Click anywhere and the following figure shows the city-(void) touchesBegan :( NSSet *) touches withEvent :( UIEvent *) event {UIActionSheet * city = [[UIActionSheet alloc] initWithTitle: @ "city selection" delegate: self cancelButtonTitle: nil destructiveButtonTitle: nil otherButtonT
[Code note] the implementation of the book flip effect, and the code note flip
Code:
RootViewController. m
# Import "RootViewController. h "@ interface RootViewController () @ end @ implementation RootViewController-(id) initWithNibName :( NSString *) bundle :( NSBundle *) handle {self = [super initWithNibName: nibNameOrNil bundle: nibBundleOrNil]; if (self) {// Custom initialization} return self;}-(void) v
Work note-pull message mechanism and note message mechanism
The message mechanism for servers and mobile phones is implemented for the first time. There is no push mechanism and messages can only be pulled. It seems a little complicated ~
This is the new flowchart. I don't know what the problem is. I hope you can give some comments or introduce some useful push methods ~
Click to view the chart
Message Mec
[Code Note] Click on the vertex to bring up another small interface, note Vertex
I ,.
2. File directory.
3. Code.
RootViewController. h
#import
RootViewController. m
# Import "RootViewController. h "@ interface RootViewController () @ end @ implementation RootViewController-(id) initWithNibName :( NSString *) bundle :( NSBundle *) handle {self = [super initWithNibName: nibNameOrNil bundle: nibBundleOr
Android development-Dynamic Layout note, android note
Compared with static la S, android dynamic la s do not need to change xml to layout code, which improves the efficiency. Of course, you can ignore it. The Dynamic Layout is mainly flexible. You can quickly modify the layout in the Code and directly use controls for business logic development. However, the amount of code is usually large, so it is not con
BroadcastingMount the Inttro_boradcastmessate script on a cubes Public classInttro_broadcastmessate:monobehaviour {//Use this for initialization voidStart () {}//Update is called once per frame voidUpdate () {}voidOnMouseDown () {print ("123"); Gameobject.find ("Cubes"). Broadcastmessage ("Changemycolor", sendmessageoptions.dontrequirereceiver);//The Changemycolor method} in the script that calls cubes's sub-object or Parent object}}Mount ChangeColor on a cubes sub-object Public class chan
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.