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 {
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
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:
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
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
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
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(..
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 "
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
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
10 matches
Mail list logo