映射后的 Xcode Reskit 在 NSLog 中以及分配给标签时得到空值
当我使用 RestKit 连接到 Web 服务时遇到另一个问题。
当我使用 (RKLogConfigureByName("RestKit/*", RKLogLevelTrace);
) 时,就可以了。有数据映射到变量。但是,当我尝试在标签中显示它或使用 NSlog 时,我得到一个 Null 值
这是我文件的一些代码,
NSString* _Biography ;
NSString* _Courses ;
NSString* _CoursesNames ;
NSString* _DOB ;
@property (nonatomic, retain) NSString* Biography ;
@property (nonatomic, retain) NSString* Courses ;
@property (nonatomic, retain) NSString* CoursesNames ;
@property (nonatomic, retain) NSString* DOB ;
@synthesize Biography =_Biography ;
@synthesize Courses=_Courses ;
@synthesize CoursesNames=_CoursesNames ;
@synthesize DOB=_DOB ;
[mapping mapKeyPathsToAttributes:
@"Biography",@"Biography",
@"Courses",@"Courses",
@"CoursesNames", @"CoursesNames",
@"DOB",@"DOB"
这是来自 (RKLogConfigureByName("RestKit/*", RKLogLevelTrace);
)
Biography = "Rita u .";
Courses = "Math”
CoursesNames = " Math001";
DOB = "Ssss";
有人有什么建议吗?
I got another issue when I connect to a webservice using RestKit.
When I used (RKLogConfigureByName("RestKit/*", RKLogLevelTrace);
) it is ok. There is data mapped to the variable. But when I try to display it in a label or when I use NSlog I get a Null value
Here is some code of my file
NSString* _Biography ;
NSString* _Courses ;
NSString* _CoursesNames ;
NSString* _DOB ;
@property (nonatomic, retain) NSString* Biography ;
@property (nonatomic, retain) NSString* Courses ;
@property (nonatomic, retain) NSString* CoursesNames ;
@property (nonatomic, retain) NSString* DOB ;
@synthesize Biography =_Biography ;
@synthesize Courses=_Courses ;
@synthesize CoursesNames=_CoursesNames ;
@synthesize DOB=_DOB ;
[mapping mapKeyPathsToAttributes:
@"Biography",@"Biography",
@"Courses",@"Courses",
@"CoursesNames", @"CoursesNames",
@"DOB",@"DOB"
this is a log from (RKLogConfigureByName("RestKit/*", RKLogLevelTrace);
)
Biography = "Rita u .";
Courses = "Math”
CoursesNames = " Math001";
DOB = "Ssss";
Does anyone have any suggestion?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您没有找到解决方案,我们可以看看您的回调函数的部分代码吗?
也许您没有使用正确重新调整的对象。
If you don't have found the solution, can we see part of code of your callback function ?
Maybe you don't use correctly retuned objects.