The tag <portlet:defineObjects/> is part of the portlet spec since 1.0.
>From the Portlet spec 1.0:

<quote>
PLT.22.1 defineObjects Tag
The defineObjects tag must define the following variables in the JSP
page:
• RenderRequest renderRequest
• RenderResponse renderResponse
• PortletConfig portletConfig
These variables must reference the same Portlet API objects stored in
the request object
of the JSP as defined in the PLT.16.3.1 Included Request Attributes
Section.
A JSP using the defineObjects tag may use these variables from
scriptlets throughout
the page.
</quote>

Brent

-----
Brent Thomas
Acutely Obtuse, Inc.
[EMAIL PROTECTED]

----- Original message -----
From: "Shane Paul" <[EMAIL PROTECTED]>
To: [email protected], [email protected]
Date: Tue, 2 May 2006 10:00:53 +1200
Subject: RE: Embedding Pluto

Hi Patrick,

Thanks for the response, but I am a little confused by your response.

I "discovered" this fix by tracing the source of a null pointer
exception. (i.e. as opposed to documentation) I know this is (probably?)
a hack and that I am missing something here, but I am not sure what.
Just wanted a heads up from someone who knows about how 1.1 works.

The main confusing bit is that <% new PortalEnvironment(request,
response); %> has only request/response dependencies and could have been
handled via a filter perhaps? 

Anyways, my question was essentially: "Is this a hack? If so, what am I
doing wrong?"


Shane

> -----Original Message-----
> From: Patrick Huber [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, 2 May 2006 3:38 a.m.
> To: [email protected]
> Subject: Re: Embedding Pluto
> 
> Hi Shane
> 
> Usually, you'd put this somewhere above the first portlet tag of a jsp
> page: <portlet:defineObjects/>. I haven't seen your scriptlet
> before... it's probably doing the same. Using the above tag is the
> recommended way of initializing portletRequest, portletResponse and a
> few other objects.
> 
> Patrick
> 
> 2006/4/30, Shane Paul <[EMAIL PROTECTED]>:
> > Well that was a mission, but it is done:
> >
> > Built the pluto driver+extras from scratch using eclipse and made it
> > compatible with spring 2.0M3.
> > Embedded it into our website using nothing more than the 
> portlet tags,
> > as originally hoped.
> > I guess now you know it can be done. Writing some docs on 
> what I did for
> > my personal and company records. If anyone is interested, just ask.
> >
> > Very happy. :)
> >
> > The only thing I cannot work out is having to add:
> > <% new PortalEnvironment(request, response); %>
> > To the jsp file before using the portlet tag. I understand it places
> > "things" into the request and/or session scope, but I am 
> not sure why
> > this does not happen when the tag is called. Will most 
> likely edit the
> > source again to add this.
> >
> > cheers.
> >
> > Shane
> >
> >
> >
> >
> 
> 
> --
> "I love deadlines. I like the whooshing sound they make as they fly
> by." -- Douglas Adams
> 

Reply via email to