RE: Re: Restlet and Velocity template location.

2010-06-02 Thread webpost
Does Anyone have working Velocity template example that uses the Classpath loader? We're running inside of tomcat and I've tried a bunch of the obvious recipes but can't get it to go. For example: @Override public Representation represent(Variant variant) throws ResourceException {

Re: Restlet and Velocity template location.

2008-05-22 Thread Jerome Louvel
Hi Stuart, You might be interested to know that in Restlet 1.1 M4, the Velocity's TemplateRepresentation can now be created by wrapping another representation instead of giving a template name. In Servlet mode, this allows you to use the WAR client to get the source representation: getCont

Re: Restlet and Velocity template location.

2008-03-10 Thread Stian Soiland-Reyes
On Wed, Mar 5, 2008 at 8:03 AM, cleverpig <[EMAIL PROTECTED]> wrote: > 1.I put template file in template directory which under > classpath:templates\people.vm,by the way,I use Eclipse to develope > these. > 2.put velocity.properties under classpath: > resource.loader = file I do it like this:

Re: Restlet and Velocity template location.

2008-03-05 Thread cleverpig
Thanks, Jerome! I stepped out this problem after a hour's work. 1.I put template file in template directory which under classpath:templates\people.vm,by the way,I use Eclipse to develope these. 2.put velocity.properties under classpath: resource.loader = file file.resource.loader.description = V

RE: Restlet and Velocity template location.

2008-02-29 Thread Jerome Louvel
Hello, > Thanks Vincent,that's pretty way for restlet-1.1snapshot.I > used this way in restlet or resource: > TemplateRepresentation templateRepr= new TemplateRepresentation( > "/people.vm", > MediaType.TEXT_HTML); > ... > templateRepr.setDataModel(dataMod

Re: Restlet and Velocity template location.

2008-02-28 Thread cleverpig
Thanks Vincent,that's pretty way for restlet-1.1snapshot.I used this way in restlet or resource: TemplateRepresentation templateRepr= new TemplateRepresentation( "/people.vm", MediaType.TEXT_HTML); ... templateRepr.setDataModel(dataModel); templateRepr.getEng

Re: Restlet and Velocity template location.

2008-02-27 Thread Vincent
Stuart, > I'm trying to use the TemplateRepresentation for the Velocity extension as > part > of a webapp, but I am having problems configuring the template location. Have you tried this: org.restlet.ext.velocity.TemplateRepresentation r = new org.restlet.ext.velocity.TemplateRepresentation(..

RE: Restlet and Velocity template location.

2007-07-06 Thread Jerome Louvel
llet 2007 11:43 > À : discuss@restlet.tigris.org > Objet : Re: Restlet and Velocity template location. > > Avi Flax arc90.com> writes: > > > > > Stuart, I myself had some issues with this recently, when developing > > my first Restlet app. However, my app is "

Re: Restlet and Velocity template location.

2007-07-03 Thread Stuart Owen
Avi Flax arc90.com> writes: > > Stuart, I myself had some issues with this recently, when developing > my first Restlet app. However, my app is "standalone", i.e. it doesn't > use the Servlet adapter to run inside a Servlet Server, it uses one of > the included extensions to embed an HTTP server

Re: Restlet and Velocity template location.

2007-07-02 Thread Avi Flax
Stuart, I myself had some issues with this recently, when developing my first Restlet app. However, my app is "standalone", i.e. it doesn't use the Servlet adapter to run inside a Servlet Server, it uses one of the included extensions to embed an HTTP server. I think that may make a big difference