已经存在一个类B,怎样声明一个类A,里面有一些成员类型分别有
long
string
list< B >
上面的这些类型,然后我不知道怎么去声明,对应的类型是什么 ?
还有一些比如copy,retain,strong等是什么类型用什么???
创建一个新的类B然后在里面声明就行
.h文件如下
#import
@interface CBTestController : UIViewController
/**
创建string类型
/
@property(nonatomic,strong)NSString customString;
/**
创建可变数组(list)
/
@property(nonatomic,strong)NSMutableArray customMutableArray;
/**
创建 float类型
*/
@property(nonatomic,assign)float f;
@end