Module: ActiveResource::Formats::JsonFormat

### Home Classes Methods

### In Files

- lib/active_resource/formats/json_format.rb

### Methods

- #decode
- #encode
- #extension
- #mime_type

### Files

- README.rdoc

### Class/Module Index

Quicksearch

- ActiveResource
- ActiveResource::Base
- ActiveResource::Connection
- ActiveResource::CustomMethods
- ActiveResource::CustomMethods::ClassMethods
- ActiveResource::Errors
- ActiveResource::Formats
- ActiveResource::Formats::JsonFormat
- ActiveResource::Formats::XmlFormat
- ActiveResource::HttpMock
- ActiveResource::InvalidRequestError
- ActiveResource::LogSubscriber
- ActiveResource::Observing
- ActiveResource::Railtie
- ActiveResource::Request
- ActiveResource::Response
- ActiveResource::SSLError
- ActiveResource::TimeoutError
- ActiveResource::Validations

No matching classes.

# ActiveResource::Formats::JsonFormat

### Public Instance Methods

decode(json) click to toggle source

    # File lib/active_resource/formats/json_format.rb, line 20
    def decode(json)
      Formats.remove_root(ActiveSupport::JSON.decode(json))
    end

encode(hash, options = nil) click to toggle source

    # File lib/active_resource/formats/json_format.rb, line 16
    def encode(hash, options = nil)
      ActiveSupport::JSON.encode(hash, options)
    end

extension() click to toggle source

    # File lib/active_resource/formats/json_format.rb, line 8
    def extension
      "json"
    end

mime_type() click to toggle source

    # File lib/active_resource/formats/json_format.rb, line 12
    def mime_type
      "application/json"
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.