Skip to content
Browse files

some quick documentation for the Image stuff

  • Loading branch information...
1 parent ab6d3c4 commit 74d5787ebb106c83539e4e6f6c5818d6329287f5 @nikz nikz committed Apr 15, 2012
Showing with 18 additions and 2 deletions.
  1. +18 −2 README.md
View
20 README.md
@@ -11,7 +11,7 @@ specific elements, see the PDF provided by Realestate.co.nz.
Creating a new client:
client = Realestate::Client.new(:public_key => YOUR_PUBLIC_KEY, :private_key => YOUR_PRIVATE_KEY)
- #=> <RealEstate::Client...>
+ #=> <Realestate::Client...>
Category methods (note that dashes in API paths are converted to underscores for Ruby method names):
@@ -33,4 +33,20 @@ Category methods (note that dashes in API paths are converted to underscores for
Listing searching, will concatenate pages automatically. Search paramters as per Realestate.co.nz documentation.
client.listings(:district_id => 1, :format => "id")
- #=> [ { "id" : 1234, ... }]
+ #=> [ { "id" : 1234, ... }]
+
+The `Realestate::Image` class represents an image on the image server. You can create images via ID or URL:
+
+ image = Realestate::Image.new(12345)
+ # => <Realestate::Image... >
+
+ image = Realestate::Image.new("http://imageserver.realestate.co.nz/1234")
+ # => <Realestate::Image... >
+
+You can download images using the download method, and the w/h/bg/mode parameters as per the documentation:
+
+ image = Realestate::Image.new(12345)
+ image.download(:w => 200, :h => 100)
+ # => <IO ... >
+
+

0 comments on commit 74d5787

Please sign in to comment.
Something went wrong with that request. Please try again.