Portlet Factory, Version 6.1.2


 

Using Java expressions for builder input

You can also enter Java syntax for the input to a builder. The IBM® WebSphere Portlet Factory runtime evaluates the Java expression at generation time, and supplies the input to the builder call with the value. You can use a Java expression for indirect references when you want to specify an element in the web application that the chooser or builder call editor does not directly support. For example, if you wanted to supply the input with the URL to the WebSphere Portlet Factory runtime, you could use the following Java expression:

${Java/webAppAccess.getRequestData().getContextURL()}

To set a text input value to the value returned by a method that takes arguments:

${Java/webAppAccess.callMethod("MethodName", arg1, arg2)}

Parent topic: About using the Choose Reference dialog


Library | Support |