Do you have any sample code that demonstrates the proper usage of the riap?
I'm running 1.0.9 so not all of the methods translate directly over to me, but
this is what I'm doing inside of my Check Status Resource:
// Create a new Component.
Component component = new Component();
// Attach the results application.
component.getDefaultHost().attach("/conditions", ConditionsResource.class);
component.getContext().getDispatcher().get("riap://conditions");
I'm attach condition resource class to the "/conditions" path, and then calling
a get on it right?
Sam Bao | Software Engineer | Cerner Corporation | 816.201.8242 | [EMAIL
PROTECTED] <mailto:[EMAIL PROTECTED]> | www.cerner.com
<http://www.cerner.com/>
________________________________
From: Rob Heittman [mailto:[EMAIL PROTECTED]
Sent: Wednesday, May 14, 2008 3:07 PM
To: [email protected]
Subject: Re: Calling a resource from another resource
You almost certainly want to use the Restlet Internal Application Protocol
(RIAP)
http://wiki.restlet.org/docs_1.1/g1/13-restlet/48-restlet/86-restlet/90-restlet/45-restlet.html
This avoids either the overhead of an external HTTP call or the risk of error
and tight bindings associated with directly calling between objects. RIAP gets
heavy exercise by my company and Marc Portier's, even if nobody else really
knows about it yet :-)
- Rob
----------------------------------------------------------------------
CONFIDENTIALITY NOTICE This message and any included attachments are from
Cerner Corporation and are intended only for the addressee. The information
contained in this message is confidential and may constitute inside or
non-public information under international, federal, or state securities laws.
Unauthorized forwarding, printing, copying, distribution, or use of such
information is strictly prohibited and may be unlawful. If you are not the
addressee, please promptly delete this message and notify the sender of the
delivery error by e-mail or you may call Cerner's corporate offices in Kansas
City, Missouri, U.S.A at (+1) (816)221-1024.