请告诉我,如何在我的XCode 4.6中为iOS5 +创建项目,其中所有版本都适用于iOS6 +
我改变了部署目标

以及如何更改基础SDK?或许我不能改变它?

我必须做的是,如果我尝试使用只能在iOS 6+中使用的方法,我的XCode会向我显示警告?
我阅读了有关单身人士和授权的足够信息.所以,我想我明白什么是单身人士.关于代表团我仍然感到困惑.我理解授权的概念,但我需要创建我的协议以理解授权.
好的,我创建单例用于与CoreData中的实体一起工作.也许我错了,它不是单身,请告诉我.我的单身人士是FetchData.
Fetchdata.h
#import <Foundation/Foundation.h>
@interface FetchData : NSObject <UIApplicationDelegate>
+(FetchData*) fetchData;
-(NSArray*)fetchLogin:(NSString*)name;
-(BOOL)newGroup:(NSString*)group forLogin:(NSString*)login;
-(NSMutableArray*)contactsForGroup:(NSString*)group;
-(BOOL)newContact:(NSString*)name surname:(NSString*)surname withDatas:(NSArray*)array;
//other methods
@end
Run Code Online (Sandbox Code Playgroud)
Fetchdata.m
#import "FetchData.h"
#import "Contact.h"
#import "Login.h"
#import "Group.h"
#import "AppDelegate.h"
@interface FetchData ()
@property (nonatomic, strong) NSEntityDescription *loginEntity;
@property (nonatomic, strong) NSEntityDescription* groupEntity;
@property (nonatomic, strong) NSManagedObjectContext* context;
@property (nonatomic, strong) NSEntityDescription* contactEntity;
@property (nonatomic, strong) AppDelegate* appDelegate;
//other properties
@end
@implementation FetchData
@synthesize //my properties
+(FetchData*) fetchData
{
static FetchData* fetchData = nil;
if (!fetchData)
fetchData …Run Code Online (Sandbox Code Playgroud) 我需要将项目上传到朋友的github帐户.我有登录名和密码.当我尝试推送项目时,它总是询问名称和密码,我尝试键入登录名和密码或github的主目录(用黑色在屏幕上画出)和密码,尝试使用空密码,但总是警告它是不正确的名称或密码.我尝试在github上创建repo并将其克隆到我的Mac,然后将文件复制到这个克隆的repo并在commit - push之后.但我再次需要输入类型名称和密码.它是什么?一些屏幕:
repo on github
Run Code Online (Sandbox Code Playgroud)

add repo in xcode
Run Code Online (Sandbox Code Playgroud)

What I need type in this fields?
Run Code Online (Sandbox Code Playgroud)

尝试键入登录名和密码,主目录和密码的标题,git-password,以及所有这些名称和空密码字段.我总是看到:

我用的是故事板.我在故事板中为我的Cell创建了一个新类,我在重用标识符"userFullCell"中编写.我的Cell类.h
#import <UIKit/UIKit.h>
@interface UsefullLinksCell : UITableViewCell
@property (weak, nonatomic) IBOutlet UIImageView *image;
@property (weak, nonatomic) IBOutlet UILabel *shortTitle;
@end
Run Code Online (Sandbox Code Playgroud)
.m默认
#import "UsefullLinksCell.h"
@implementation UsefullLinksCell
- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
if (self) {
// Initialization code
}
return self;
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated
{
[super setSelected:selected animated:animated];
// Configure the view for the selected state
}
Run Code Online (Sandbox Code Playgroud)
属性图像和shortTitle在故事板中与UILabel和Cell中的UIImageView连接
然后在我的UITableView类中导入"UseFullLinksCell.h"并在viewDidLoad中写道:
[self.tableView registerClass:[UsefullLinksCell class] forCellReuseIdentifier:@"userFullCell"];
Run Code Online (Sandbox Code Playgroud)
tableView是我的出路:
@property (weak, nonatomic) IBOutlet UITableView *tableView;
Run Code Online (Sandbox Code Playgroud)
然后我尝试创建单元格:
- …Run Code Online (Sandbox Code Playgroud) 今天我读了Carlo Chung的"Pro Objective-C Design Patterns for iOS".所以我读了一下Adapter Pattern并看到在协议中声明了这个方法:
-(void) command: (SetStrokeColorCommand *) command
didRequestColorComponentsForRed: (CGFloat *) red
green: (CGFloat *) green
blue: (CGFloat *) blue;
Run Code Online (Sandbox Code Playgroud)
您可以在第115页的书中看到它.比使用这种方法
[delegate_ command:self didRequestColorComponentsForRed: &redValue
green: &greenValue
blue: &blueValue];
Run Code Online (Sandbox Code Playgroud)
然后在第118页声明此方法
-(void) command: (SetStrokeColorCommand *) command
didRequestColorComponentsForRed: (CGFloat *) red
green: (CGFloat *) green
blue: (CGFloat *) blue
{
*red = [redSlider_ value];
*green = [greenSlider_ value];
*blue = [blueSlider_ value];
}
Run Code Online (Sandbox Code Playgroud)
声明中的含义*(*红色,*绿色,*蓝色)和含义(&redValue ...)是什么意思?我在代码中看到&只有&错误.
ios ×4
xcode ×4
objective-c ×3
iphone ×2
delegates ×1
git ×1
github ×1
singleton ×1
uitableview ×1