Created
November 6, 2015 11:15
-
-
Save yannxou/14866feb2762cecbf068 to your computer and use it in GitHub Desktop.
Swift: Declaring var with private setter
This file contains hidden or 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
| // Var only setteable from private access level but with internal access (default) on its getter | |
| private(set) var info = "" | |
| // Var only setteable from private access level but with public access on its getter | |
| public private(set) var info = "" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment