Class: NSURL
- Defined in:
- lib/cocoa/sugarcube-to_s/nsurl.rb,
lib/cocoa/sugarcube-nsdata/nsurl.rb,
lib/cocoa/sugarcube-foundation/nsurl.rb
Instance Method Summary collapse
- #can_open? ⇒ Boolean
- #inspect ⇒ Object
- #nsdata ⇒ Object
- #nsmutableurlrequest ⇒ Object
- #nsurl ⇒ Object
- #nsurlrequest ⇒ Object
- #open ⇒ Object
- #to_s ⇒ Object
Instance Method Details
#can_open? ⇒ Boolean
7 8 9 |
# File 'lib/cocoa/sugarcube-foundation/nsurl.rb', line 7 def can_open? UIApplication.sharedApplication.canOpenURL(self) end |
#inspect ⇒ Object
7 8 9 10 11 |
# File 'lib/cocoa/sugarcube-to_s/nsurl.rb', line 7 def inspect "#<#{self.class.to_s}:0x#{self.object_id.to_s(16)}, "+ "URL=#{self.absoluteString.inspect}"+ ">" end |
#nsdata ⇒ Object
3 4 5 |
# File 'lib/cocoa/sugarcube-nsdata/nsurl.rb', line 3 def nsdata NSData.dataWithContentsOfURL(self) end |
#nsmutableurlrequest ⇒ Object
19 20 21 |
# File 'lib/cocoa/sugarcube-foundation/nsurl.rb', line 19 def nsmutableurlrequest NSMutableURLRequest.alloc.initWithURL(self) end |
#nsurl ⇒ Object
11 12 13 |
# File 'lib/cocoa/sugarcube-foundation/nsurl.rb', line 11 def nsurl self end |
#nsurlrequest ⇒ Object
15 16 17 |
# File 'lib/cocoa/sugarcube-foundation/nsurl.rb', line 15 def nsurlrequest NSURLRequest.requestWithURL(self) end |
#open ⇒ Object
3 4 5 |
# File 'lib/cocoa/sugarcube-foundation/nsurl.rb', line 3 def open UIApplication.sharedApplication.openURL(self) end |
#to_s ⇒ Object
3 4 5 |
# File 'lib/cocoa/sugarcube-to_s/nsurl.rb', line 3 def to_s self.absoluteString end |