mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
Fixed merge error
This commit is contained in:
256
declarations.ios.d.ts
vendored
256
declarations.ios.d.ts
vendored
@@ -2,160 +2,164 @@
|
|||||||
// iOS specific TypeScript declarations
|
// iOS specific TypeScript declarations
|
||||||
// TODO: This is temporary, until we have the TS definitions for the native APIs
|
// TODO: This is temporary, until we have the TS definitions for the native APIs
|
||||||
|
|
||||||
/*
|
|
||||||
declare module UIKit {
|
|
||||||
|
|
||||||
export class UIResponder {
|
//declare module UIKit {
|
||||||
static extends(param1: any, param2: any): any;
|
|
||||||
}
|
|
||||||
|
|
||||||
export class UIWindow {
|
// export class UIResponder {
|
||||||
constructor(frame: any);
|
// static extends(param1: any, param2: any): any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class UIScreen {
|
// export class UIWindow {
|
||||||
static mainScreen(): any;
|
// constructor(frame: any);
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class UIColor {
|
// export class UIScreen {
|
||||||
static whiteColor: any;
|
// static mainScreen(): any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class UINavigationController {
|
// export class UIColor {
|
||||||
constructor(rootController: any);
|
// static whiteColor: any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class UIImageView {
|
// export class UINavigationController {
|
||||||
constructor();
|
// constructor(rootController: any);
|
||||||
setImage(image: any);
|
// }
|
||||||
}
|
|
||||||
|
|
||||||
export class UILabel {
|
// export class UIImageView {
|
||||||
constructor();
|
// constructor();
|
||||||
setText(text: string);
|
// setImage(image: any);
|
||||||
sizeToFit();
|
// }
|
||||||
}
|
|
||||||
|
|
||||||
export class UIImage {
|
// export class UILabel {
|
||||||
static imageNamed(name: string): UIImage;
|
// constructor();
|
||||||
static imageWithContentsOfFile(path: string): UIImage;
|
// setText(text: string);
|
||||||
static imageWithData(data: any): UIImage;
|
// sizeToFit();
|
||||||
}
|
// }
|
||||||
|
|
||||||
function UIImagePNGRepresentation(image: UIImage);
|
// export class UIImage {
|
||||||
function UIImageJPEGRepresentation(image: UIImage, compressionQuality: number);
|
// static imageNamed(name: string): UIImage;
|
||||||
}
|
// static imageWithContentsOfFile(path: string): UIImage;
|
||||||
|
// static imageWithData(data: any): UIImage;
|
||||||
|
// }
|
||||||
|
|
||||||
declare module Foundation {
|
// function UIImagePNGRepresentation(image: UIImage);
|
||||||
export class NSError extends NSObject {
|
// function UIImageJPEGRepresentation(image: UIImage, compressionQuality: number);
|
||||||
}
|
//}
|
||||||
|
|
||||||
export class NSObject {
|
//declare module Foundation {
|
||||||
static extends(...optionalParams: any[]): any;
|
// export class NSError extends NSObject {
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class NSUserDefaults {
|
// export class NSObject {
|
||||||
static standardUserDefaults(): any;
|
// static extends(...optionalParams: any[]): any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class NSMutableArray {
|
// export class NSUserDefaults {
|
||||||
addObject(obj: any);
|
// static standardUserDefaults(): any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class NSFileManager {
|
// export class NSMutableArray {
|
||||||
static defaultManager(): NSFileManager;
|
// addObject(obj: any);
|
||||||
URLsForDirectoryInDomains(directory: number, mask: number): any;
|
// }
|
||||||
attributesOfItemAtPathError(path: string, error: any): any;
|
|
||||||
fileExistsAtPath(path: string): boolean;
|
|
||||||
fileExistsAtPathIsDirectory(path: string, isDir: boolean): boolean;
|
|
||||||
createDirectoryAtPathWithIntermediateDirectoriesAttributesError(path: string, intermediateDirs: boolean, attributes: any, error: any): boolean;
|
|
||||||
displayNameAtPath(path: string): string;
|
|
||||||
createFileAtPathContentsAttributes(path: string, data: any, attributes: any): boolean;
|
|
||||||
enumeratorAtPath(path: string): any;
|
|
||||||
contentsOfDirectoryAtPathError(path: string, error: any);
|
|
||||||
removeItemAtPathError(path: string, error: any): boolean;
|
|
||||||
moveItemAtPathToPathError(sourcePath: string, destPath: string, error: any);
|
|
||||||
contentsAtPath(path: string): NSData;
|
|
||||||
}
|
|
||||||
|
|
||||||
export class NSData extends NSObject {
|
// export class NSFileManager {
|
||||||
|
// static defaultManager(): NSFileManager;
|
||||||
|
// URLsForDirectoryInDomains(directory: number, mask: number): any;
|
||||||
|
// attributesOfItemAtPathError(path: string, error: any): any;
|
||||||
|
// fileExistsAtPath(path: string): boolean;
|
||||||
|
// fileExistsAtPathIsDirectory(path: string, isDir: boolean): boolean;
|
||||||
|
// createDirectoryAtPathWithIntermediateDirectoriesAttributesError(path: string, intermediateDirs: boolean, attributes: any, error: any): boolean;
|
||||||
|
// displayNameAtPath(path: string): string;
|
||||||
|
// createFileAtPathContentsAttributes(path: string, data: any, attributes: any): boolean;
|
||||||
|
// enumeratorAtPath(path: string): any;
|
||||||
|
// contentsOfDirectoryAtPathError(path: string, error: any);
|
||||||
|
// removeItemAtPathError(path: string, error: any): boolean;
|
||||||
|
// moveItemAtPathToPathError(sourcePath: string, destPath: string, error: any);
|
||||||
|
// contentsAtPath(path: string): NSData;
|
||||||
|
// }
|
||||||
|
|
||||||
}
|
// export class NSData extends NSObject {
|
||||||
|
|
||||||
export class NSString {
|
// }
|
||||||
static initWithString(s: string): NSString;
|
|
||||||
static initWithDataEncoding(data: any, encoding: any): any;
|
|
||||||
static pathWithComponents(paths: NSArray): NSString;
|
|
||||||
static stringWithContentsOfFileEncodingError(path: string, encoding: number, error: any): NSString;
|
|
||||||
stringByDeletingLastPathComponent(): string;
|
|
||||||
stringByDeletingPathExtension(): string;
|
|
||||||
dataUsingEncoding(encoding: number): any;
|
|
||||||
writeToFileAtomicallyEncodingError(path: string, atomically: boolean, encoding: number, error: any): boolean;
|
|
||||||
}
|
|
||||||
|
|
||||||
export class NSArray extends NSObject {
|
// export class NSString {
|
||||||
static arrayWithObjectsWithArguments(...params: any[]): NSArray;
|
// static initWithString(s: string): NSString;
|
||||||
}
|
// static initWithDataEncoding(data: any, encoding: any): any;
|
||||||
|
// static pathWithComponents(paths: NSArray): NSString;
|
||||||
|
// static stringWithContentsOfFileEncodingError(path: string, encoding: number, error: any): NSString;
|
||||||
|
// stringByDeletingLastPathComponent(): string;
|
||||||
|
// stringByDeletingPathExtension(): string;
|
||||||
|
// dataUsingEncoding(encoding: number): any;
|
||||||
|
// writeToFileAtomicallyEncodingError(path: string, atomically: boolean, encoding: number, error: any): boolean;
|
||||||
|
// }
|
||||||
|
|
||||||
export class NSURLSessionConfiguration {
|
// export class NSArray extends NSObject {
|
||||||
static defaultSessionConfiguration(): any;
|
// static arrayWithObjectsWithArguments(...params: any[]): NSArray;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class NSOperationQueue {
|
// export class NSURLSessionConfiguration {
|
||||||
static mainQueue(): any;
|
// static defaultSessionConfiguration(): any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class NSURLSession {
|
// export class NSOperationQueue {
|
||||||
static sessionWithConfigurationDelegateDelegateQueue(config: any, param: any, queue : any): any;
|
// static mainQueue(): any;
|
||||||
}
|
// }
|
||||||
|
|
||||||
export class NSURL {
|
// export class NSURLSession {
|
||||||
static URLWithString(url: string): NSURL;
|
// static sessionWithConfigurationDelegateDelegateQueue(config: any, param: any, queue : any): any;
|
||||||
static fileURLWithPathIsDirectory(path: string, isDirectory: boolean): NSURL;
|
// }
|
||||||
path(): string;
|
|
||||||
relativePath(): string;
|
|
||||||
relativeString(): string;
|
|
||||||
pathExtension(): string;
|
|
||||||
}
|
|
||||||
|
|
||||||
export class NSDate {
|
// export class NSURL {
|
||||||
static dateWithTimeIntervalSince1970(datetime: number);
|
// static URLWithString(url: string): NSURL;
|
||||||
timeIntervalSince1970(): number;
|
// static fileURLWithPathIsDirectory(path: string, isDirectory: boolean): NSURL;
|
||||||
}
|
// path(): string;
|
||||||
|
// relativePath(): string;
|
||||||
|
// relativeString(): string;
|
||||||
|
// pathExtension(): string;
|
||||||
|
// }
|
||||||
|
|
||||||
export class NSMutableURLRequest {
|
// export class NSDate {
|
||||||
static requestWithURL(url: any): any;
|
// static dateWithTimeIntervalSince1970(datetime: number);
|
||||||
}
|
// timeIntervalSince1970(): number;
|
||||||
}
|
// }
|
||||||
|
|
||||||
declare module QuartzCore {
|
// export class NSMutableURLRequest {
|
||||||
function CACurrentMediaTime(): number;
|
// static requestWithURL(url: any): any;
|
||||||
}
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
declare module CoreLocation {
|
//declare module QuartzCore {
|
||||||
export class CLLocationManager {
|
// function CACurrentMediaTime(): number;
|
||||||
static locationServicesEnabled(): boolean;
|
//}
|
||||||
delegate: any;
|
|
||||||
distanceFilter: number;
|
|
||||||
desiredAccuracy: number;
|
|
||||||
startUpdatingLocation(): void;
|
|
||||||
stopUpdatingLocation(): void;
|
|
||||||
location: CLLocation;
|
|
||||||
}
|
|
||||||
|
|
||||||
export class CLLocation {
|
//declare module CoreLocation {
|
||||||
static initWithCoordinateAltitudeHorizontalAccuracyVerticalAccuracyCourseSpeedTimestamp(coordinate: any, altitude: number, horizontalAccuracy: number, verticalAccuracy: number, course: number, speed: number, timestamp: Foundation.NSDate);
|
// export class CLLocationManager {
|
||||||
coordinate: any;
|
// static locationServicesEnabled(): boolean;
|
||||||
altitude: number;
|
// delegate: any;
|
||||||
horizontalAccuracy: number;
|
// distanceFilter: number;
|
||||||
verticalAccuracy: number;
|
// desiredAccuracy: number;
|
||||||
timestamp: Foundation.NSDate;
|
// startUpdatingLocation(): void;
|
||||||
speed: number;
|
// stopUpdatingLocation(): void;
|
||||||
course: number;
|
// location: CLLocation;
|
||||||
}
|
// }
|
||||||
|
|
||||||
function CLLocationCoordinate2DMake(latitude: number, longitude: number) : any;
|
// export class CLLocation {
|
||||||
}
|
// static initWithCoordinateAltitudeHorizontalAccuracyVerticalAccuracyCourseSpeedTimestamp(coordinate: any, altitude: number, horizontalAccuracy: number, verticalAccuracy: number, course: number, speed: number, timestamp: Foundation.NSDate);
|
||||||
|
// coordinate: any;
|
||||||
|
// altitude: number;
|
||||||
|
// horizontalAccuracy: number;
|
||||||
|
// verticalAccuracy: number;
|
||||||
|
// timestamp: Foundation.NSDate;
|
||||||
|
// speed: number;
|
||||||
|
// course: number;
|
||||||
|
// }
|
||||||
|
|
||||||
|
// function CLLocationCoordinate2DMake(latitude: number, longitude: number) : any;
|
||||||
|
//}
|
||||||
|
|
||||||
|
//declare var NativePointer: any;
|
||||||
|
//declare var PrimitiveType: any;
|
||||||
|
//declare var RefValue: any;
|
||||||
|
|
||||||
declare var NativePointer: any;
|
declare var NativePointer: any;
|
||||||
declare var PrimitiveType: any;
|
declare var PrimitiveType: any;
|
||||||
|
|||||||
Reference in New Issue
Block a user