If you want your portlet to support Edit mode, select Enable users to edit portlet If you want to create a portlet that supports Oracle WSRP 2.0 extensions, select

6-18 Oracle Fusion Middleware Developers Guide for Oracle Portal Figure 6–8 Content Types and Portlet Modes Page

19. By default, your portlet will display texthtml as the content type. If you want to

add other content types, select texthtml, then click Add. The list of available content types displays Figure 6–9 . Select the desired content types in the Available list and use the arrow buttons to move them to the Selected list. When you are finished, click OK. Figure 6–9 Content Types Dialog Box

20. By default, your portlet includes view mode. If you selected Editable on the

General Portlet Properties page, your portlet also includes Edit mode. If you want to include additional portlet Show modes, select an existing Show mode for example, view, then click Add. The list of available portlet Show modes displays Figure 6–10 . You can add Show modes by moving the desired modes from the Available list to the Selected list. When you are finished, click OK. For more information about portlet Show modes, see Section 6.1, Guidelines for Writing Java Portlets. Creating Java Portlets 6-19 Figure 6–10 Portlet Modes Dialog Box 21. Once you have added all of the desired portlet Show modes, choose a function to be performed for each mode. For each portlet mode, click the portlet mode and select an option on the right as follows: ■ Select Generate JSP if you want Oracle JDeveloper to generate a JSP for the portlet mode. Enter a name for the JSP in the corresponding field, or accept the defaults. When you complete the wizard, the generated JSP displays in the Application Navigator where it can be selected for further development. This is the default selection for all portlet display modes. This selection enters code in the generated portlet java class that routes requests for the given mode to the generated JSP. ■ Select Generate ADF-Faces JSPX to generate .jspx files. The .jspx files will generate exactly the same markup as JSPs. ■ Select Map to Path if you want to map the portlet to an existing Web resource, such as a page. Enter the path in the corresponding field. With this selection, you must write the targeted resource or file yourself. The target could be, for example, a JSP, a servlet, or an HTML file. This selection enters code in the generated portlet java class that routes requests for the given mode to the specified target. ■ Select Custom Code if you want to implement the portlet mode through a custom coded object. You will create this object later. This selection generates a skeleton method to render content private void doMODE_ NAMECONTENT_TYPE in the generated portlet Java class. You must update this code to render useful content.

22. Click Next.

If you selected Editable on the General Portlet Properties page earlier in the wizard, then the Customization Preferences page displays Figure 6–11 . Go to step 23. If you did not select this option, then the Security Roles page displays Figure 6–13 . Go to step 31.