-
1. Re: How to access in code to the Window Properties map in do
brownfielda Jul 2, 2007 11:49 AM (in response to pavel.myshkin)Not sure of the specific answers, but the API lists some methods for javax.portlet.RenderRequest that may help.
In particular, it has inherited the following methods from javax.portlet.PortalRequest:
getAttribute()
getParamater()
getPreferences()
getProperties()
I get those 4 types confused on a regular basis, but the JSR168 spec does well to straighten me out. Regardless, I believe that window properties can be accessed using one of those methods. -
2. Re: How to access in code to the Window Properties map in do
pavel.myshkin Jul 8, 2007 5:13 AM (in response to pavel.myshkin)Well done, Grasshopper
I can put the '.' after the request object too... called O-O-P nowdays..
And by the way neither one of them satisfies my question.
If you debug a portlet, and stop in doView, for example, you can get to the widow properties and see your custom property there deep inside window context.
I tried to dig from different directions to these properties, by acquiring and casting attribute objects and casting them to their classes... well nothing helps to get to these properties.
Maybe someone from the JBoss Portal Team can suggest anything??? -
3. Re: How to access in code to the Window Properties map in do
theute Jul 8, 2007 9:13 AM (in response to pavel.myshkin)Making fun of other on the forum won't help you. Thanks brownfielda for trying to help, please don't let him stop you from helping others.
-
4. Re: How to access in code to the Window Properties map in do
pavel.myshkin Jul 8, 2007 9:32 AM (in response to pavel.myshkin)OK. the answer is:
CorePortalNode root = Navigation.getCurrentNode();
Map hm = root.getProperties(); // WINDOW PROPERTIES MAP
Set serta = hm.entrySet();
Iterator itr = serta.iterator();
while(itr.hasNext()){
Entry entry = (Entry)itr.next();
out.write("Properties:" + entry.getKey() + "=" + entry.getValue()+ "");
}
Hooooraaaay!!!
Enjoy unlimited architecture designs!!! -
5. Re: How to access in code to the Window Properties map in do
pavel.myshkin Jul 8, 2007 9:45 AM (in response to pavel.myshkin)"thomas.heute@jboss.com" wrote:
Making fun of other on the forum won't help you. Thanks brownfielda for trying to help, please don't let him stop you from helping others.
This is R&D with bleeding edge technologies we are talking about here, and not "Intro Into Java". The one posting an answer must know the approximate level of the one`s question. -
6. Re: How to access in code to the Window Properties map in do
theute Jul 8, 2007 10:14 AM (in response to pavel.myshkin)When people make the effort to answer other people, you just don't make fun of them.
If you are not satisfied by the level of the answers on the forum, you can request professional support, that's why it exists.
No harm done, but please don't refrain people from trying to help, they have nothing to earn. -
7. Re: How to access in code to the Window Properties map in do
brownfielda Jul 9, 2007 8:32 AM (in response to pavel.myshkin)please don't let him stop you from helping others.
HA! I've got much thicker skin than that. Thanks for the support though. -
8. Re: How to access in code to the Window Properties map in do
pavel.myshkin Jul 10, 2007 8:15 AM (in response to pavel.myshkin)For 2.6 GA CorePortalNode has changed to PortalNodeImpl.