This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ git commit -am"commit message"` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ pod lib create [Library name] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum Japan { | |
enum Tokyo: String { | |
case shibuya, shinagawa, ebisu | |
} | |
enum Kanagawa: String { | |
case yokohama, kawasaki, sagamihara | |
} | |
case tokyo(Tokyo) | |
case kanagawa(Kanagawa) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class SYButton: UIButton { | |
... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UIColor.blackColor().CGColor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
stream | |
.buffer(関数) | |
.map(関数) | |
.filter(関数) | |
.subscribe(処理) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ClassName<TypeParameter> { | |
//Class statements | |
} | |
var class = ClassName<TypeParameter>() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
(paramerters) -> return type in | |
statements | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void main(String[] args) { | |
Manager manager = new Manager(); | |
UnderLinepen upen = new UnderLinePen('-'); | |
MessageBox mbox = new MessageBox('@'); | |
MessageBox sbox = new MessageBox('♪'); | |
manager.register("stong message", upen); | |
manager.register("warning box", mbox); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void main(String[] args) { | |
Singleton instance1 = Singleton.getInstance(); | |
Singleton instance2 = Singleton.getInstance(); | |
if (instance1 == instance2) { | |
System.out.println("instance1 and instance2 are same Instance"); | |
} else { | |
System.out.println("instance1 and instance2 aren't same Instance"); | |
} | |
} |