#41 ✓resolved
Guilherme Silveira

Common and Client is mixed up

Reported by Guilherme Silveira | April 15th, 2010 @ 04:00 PM | in v0.8

Restfulie::Common and Restfulie::Client dependencies are mixed up. Currently, Representation is in the Common package but if your client code, therefore if your Representation requires accessing Client, it is too early to do that, obliying you to replicate code among Common and Client. i.e.:

module Restfulie::Common::Representation
class Link

def initialize(options = {})
  @options = options
end
def href
  @options["href"]
end
def rel
  @options["rel"]
end

end

::Hash.instance_eval {

include Restfulie::Client::HTTP::LinkShortcut

}

# Implements the interface for marshal Xml media type requests (application/xml) class XmlD

cattr_reader :media_type_name
@@media_type_name = 'application/xml'

cattr_reader :headers
@@headers = { 
  :post => { 'Content-Type' => media_type_name }
}

def unmarshal(string)
  Hash.from_xml(string)
end

def marshal(string, rel)
  string
end

end

end

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Shared Ticket Bins

People watching this ticket

Tags

Pages