Hi,
you could consume the response in the same way as you created it: If you put a
xml representation, you could also get it from the request
(request.getEntityAs*() )
If you have a JSON representation, you could use
JsonRepresentation jsonEntity = new JsonRepresentation(request.getEntity() ) ;
Hi Cliff,
as a workaround, you can derive the Router class and override the
getNext method. It will give you access to the route, and then the
matched pattern:
Router router = new Router(getContext()) {
@Override
public Restlet getNext(Request request, Response
When making a Client call, I think it would be helpful to set the
confidential attribute on the Request for the user based on the Protocol.
I.e., if I'm using the HTTPS protocol, I shouldn't have to remember to set
the confidential attribute to true on every Request. I'm not where the best
place
Both the Application class and SpringRouter classes are instances of Restlet
so I don't believe you need an Application instance.
Wherever you have injected your SpringRouter, simply inject your Guard class
with the SpringRouter as the next property.
Kevin
On Mon, Oct 20, 2008 at 8:19 AM,
Not disagreeing -- makes sense -- but just curious, how/when do you use this
on the Client side? The Server side sets this if the request has come in
via https: or riap:, and that's where I usually need to interrogate it.
On Tue, Oct 21, 2008 at 8:56 AM, Kevin Conaway [EMAIL PROTECTED]wrote:
Hi Jerome (or anyone else..),
I am following your chapter in Restful Web Services by Oreilly and am
working on getting the services server up and running. i keep getting the
following :
Exception in thread main java.lang.NoClassDefFoundError:
org/mortbay/jetty/Connector
can you please advise
Thx. Mark, I appreciate your response. Looking at a REST response from a vendor
who we are trying to link up with, the xml is self describing through a type
attribute (datetime, integer...):
created-at type=datetime2008-10-01T04:45:19Z/created-at
description1/8 UNION/description
id
Hi Stephan,
Currently we are not creating the REST response. Rather we are making calls to a
vendor's REST api.
The response is not going to be readily consumed by a client, which is where I
believe the JSON representation would make sense. We are going to persisted a
representation of the
I have a restlet application being packaged inside an ear and deployed to
jboss. I have
some simple resources working fine and printing output over http in a browser.
Now, I'm trying to add a Directory resource to the application as part of my
testing.
The first time I tried this I got errors
Richard,
The only advice Richardson seems to offer on incoming representations is
that a client should be able to fetch a representation, modify it, and
PUT it back where it found it.
HTTP 1.1 rev01 add the concept of partial PUT for a brielf period of time.
This is from http 1.1 rev 01:
Erik,
Great question. Its not so much that the routes change at runtime
(although I was contemplating user-configurable routingwouldnt that be
intriguing!), but I want the behavior to change at runtime. Ultimately, we
will allow users to define their own behaviors (you dont like the XML
Hugh, good day.
Here are the jars I use under Netbeans 6.1 to avail myself of the
Jetty connector, all of which (I believe) should be available in the
Restlet distribution:
com.noelios.restlet.ext.jetty_6.1.jar
org.mortbay.jetty_6.1/org.mortbay.jetty.jar
org.mortbay.jetty.https.jar
Thierry,
This works great, thank you very, very much! I now have fully dynamic
behaviors.
Can I suggest that you make this a standard attribute? Regardless, this
works for me.
Cliff Binstock
Coyote Reporting
_
From: Thierry Boileau [mailto:[EMAIL PROTECTED]
Sent: Tuesday,
I think I was missing the forest for the trees on this. I am kind of a framework
junkie, but in hindsight since I am only consuming the rest response I don't
really need restlets at all. Basically I just need to suck the response into a
dom, and then use jaxb with annotations to create the
Hi,
buzzterrier wrote:
I think I was missing the forest for the trees on this. I am kind of a framework
junkie, but in hindsight since I am only consuming the rest response I don't
really need restlets at all. Basically I just need to suck the response into a
dom, and then use jaxb with
Hi Brian,
I've been adding the FILE client connector by creating a new component
and feeding that to the restlet that requires it. Like so:
Component component = new Component();
component.getClients().add(Protocol.FILE);
Directory directory = new
16 matches
Mail list logo