- Service available?
- callback:
service_available? - false:
503 Service Unavailable
- callback:
- Known method?
- callback:
known_methods
- callback:
- absent:
501 Not Implemented
This file contains hidden or 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
| require 'formula' | |
| class Libav < Formula | |
| homepage 'http://libav.org/' | |
| url 'http://libav.org/releases/libav-9_beta2.tar.xz' | |
| sha1 'acb7ffbcded06e5f04e8fd0f7dbcc923fd95df3f' | |
| head 'git://git.libav.org/libav.git' | |
| option "without-x264", "Disable H264 encoder" |
This file contains hidden or 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
| require 'bundler/setup' | |
| require 'roar/representer/json' | |
| require 'roar/representer/feature/hypermedia' | |
| require 'webmachine' | |
| class Product | |
| include Roar::Representer::JSON | |
| include Roar::Representer::Feature::Hypermedia | |
| property :name |
This file contains hidden or 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
| require "webmachine" | |
| class MethodOverride < Webmachine::Resource | |
| def allowed_methods | |
| override_method! | |
| %w(GET PUT DELETE) | |
| end | |
| private |
This file contains hidden or 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
| # Please ignore this solution. It's too complicated :-( | |