diff options
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT PI/cocoa/org/eclipse/swt/internal/cocoa/NSURLResponse.java')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT PI/cocoa/org/eclipse/swt/internal/cocoa/NSURLResponse.java | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/cocoa/org/eclipse/swt/internal/cocoa/NSURLResponse.java b/bundles/org.eclipse.swt/Eclipse SWT PI/cocoa/org/eclipse/swt/internal/cocoa/NSURLResponse.java new file mode 100644 index 0000000000..b6a6b4c82a --- /dev/null +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/cocoa/org/eclipse/swt/internal/cocoa/NSURLResponse.java @@ -0,0 +1,42 @@ +package org.eclipse.swt.internal.cocoa; + +public class NSURLResponse extends NSObject { + +public NSURLResponse() { + super(); +} + +public NSURLResponse(int id) { + super(id); +} + +public NSString MIMEType() { + int result = OS.objc_msgSend(this.id, OS.sel_MIMEType); + return result != 0 ? new NSString(result) : null; +} + +public NSURL URL() { + int result = OS.objc_msgSend(this.id, OS.sel_URL); + return result != 0 ? new NSURL(result) : null; +} + +public long expectedContentLength() { + return (long)OS.objc_msgSend(this.id, OS.sel_expectedContentLength); +} + +public id initWithURL(NSURL URL, NSString MIMEType, int length, NSString name) { + int result = OS.objc_msgSend(this.id, OS.sel_initWithURL_1MIMEType_1expectedContentLength_1textEncodingName_1, URL != null ? URL.id : 0, MIMEType != null ? MIMEType.id : 0, length, name != null ? name.id : 0); + return result != 0 ? new id(result) : null; +} + +public NSString suggestedFilename() { + int result = OS.objc_msgSend(this.id, OS.sel_suggestedFilename); + return result != 0 ? new NSString(result) : null; +} + +public NSString textEncodingName() { + int result = OS.objc_msgSend(this.id, OS.sel_textEncodingName); + return result != 0 ? new NSString(result) : null; +} + +} |