O'Reilly logo

IBM Rational Application Developer V6 Portlet Application Development and Portal Tools by Ryan Wilson, Gianfranco Rutigliano, George Kroner, Belen Gonzalez, Karla Galvan, Cristiano Cesario, Juan R. Rodriguez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

21.4. Using passive credentials

In the previous section, a portlet using an active credential object was built. Although this is the preferred type of credential object, there are certain cases where you have to use passive credential objects, for example when an appropriate active credential class is not available.

In this sample scenario, the portlet will be changed to use a passive credential object. To modify the portlet application, proceed as follows:

1.
In the CredentialJSR project, open the CredentialJSRPortletSecretManager class.
2.
Using the Java editor, add to the class the method shown in Example 21-8 to support passive credentials.
Example 21-8. The getConnectionUsingPassiveObject method (passive credentials)
							public static HttpURLConnection ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required