Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Can a method definition specify that a parameter must be a constant?
- + (void) replace_text_with: (NSString *) const predefined_text_style;
- typedef enum {
- FOOMy1stValue,
- FOOMy2ndValue,
- FOOMy3rdValue
- } FOOEnum;
- NSString *FOOGetStringFromEnum(FOOEnum e) {
- static NSString *strings[] = {
- @"My first value",
- @"My second value",
- @"My third value"
- };
- return strings[e];
- }
- void FOORestrictedInput(FOOEnum e) {
- NSLog(@"Restricted string: %@", FOOGetStringFromEnum(e));
- }
Advertisement
Add Comment
Please, Sign In to add comment