Kayıtlar

Eylül, 2012 tarihine ait yayınlar gösteriliyor

Short information about the first iphone development

Resim
The @autoreleasepool statement supports the Automatic Reference Counting (ARC) system. ARC provides automatic object-lifetime management for your app, ensuring that objects remain in existence for as long as they're needed and no longer. The call to UIApplicationMain creates an instance of the UIApplication class and an instance of the app delegate (in this tutorial, the app delegate is HelloWorldAppDelegate , which is provided for you by the Single View template). The main job of the app delegate is to provide the window into which your app’s content is drawn. The app delegate can also perform some app configuration tasks before the app is displayed. ( Delegation is a design pattern in which one object acts on behalf of, or in coordination with, another object.) In an iOS app, a window object provides a container for the app’s visible content, helps deliver events to app objects, and helps the app respond to changes in the device’s orientation. The window itself...

How to loop ArrayList in Java

No nonsense, four ways to loop ArrayList in Java For loop For loop (Advance) While loop Iterator loop package com.mkyong.core ;   import java.util.ArrayList ; import java.util.Iterator ; import java.util.List ;   public class ArrayListLoopingExample { public static void main ( String [ ] args ) {   List < String > list = new ArrayList < String > ( ) ; list. add ( "Text 1" ) ; list. add ( "Text 2" ) ; list. add ( "Text 3" ) ;   System . out . println ( "#1 normal for loop" ) ; for ( int i = 0 ; i < list. size ( ) ; i ++ ) { System . out . println ( list. get ( i ) ) ; }   System . out . println ( "#2 advance for loop" ) ; for ( String temp : list ) { System . out . println ( temp ) ; }   System . out . println ( "#3 while loop" ) ; int j = 0 ; while ( list. size ( ) > j ) { System . out . println ( list. get ( j ...