Created
May 26, 2012 01:24
-
-
Save rogerleite/2791620 to your computer and use it in GitHub Desktop.
Restfolia - Adapter para migracao do Restfulie
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Restfolia - Restfulie | |
- Resource Read Write; | |
- Resource com interface Hash; | |
- Links com metodos; | |
- Alias get -> get!; | |
- Some Alias | |
## Resource Read Write | |
Ex: | |
content = Restfulie.at("url").get! | |
content.resultado # => ["xxx", "zzz"] | |
content.resultado = ["teste"] | |
## Resource com interface Hash | |
Ex: | |
content = Restfulie.at("url").get! | |
content["resultado"] # => ["xxx", "zzz"] | |
content["resultado"] = ["teste"] | |
## Links com metodos | |
content = Restfulie.at("url").get! | |
content.links.rel.get! # its the same as content.links("rel").get | |
## Some Alias | |
Restfulie.at("url").get! # alias to get |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment