
IBM Host Access Transformation Services Web Application Programmer's Guide Ve r s i o n 9.5 SC27-5902-01 IBM Host Access Transformation Services Web Application Programmer's Guide Ve r s i o n 9.5 SC27-5902-01 Note Before using this information and the product it supports, be sure to read the general information under Appendix B, “Notices,” on page 165 Tenth Edition (November 2015) © Copyright IBM Corporation 2003, 2015. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Figures ...................................vii Tables ....................................ix Chapter 1. Introduction .............................1 Code examples ..................................2 Using the API documentation (Javadoc) ..........................2 Chapter 2. Adding business logic.........................3 Incorporating Java code from other applications .......................4 Using global variables in business logic ..........................5 Business logic examples ...............................7 Example: Date conversion ..............................7 Example: Adding values that are contained in an indexed global variable ..............8 Example: Reading a list of strings from a file into an indexed global variable .............9 Example: Calling an Integration Object .........................10 Using custom screen recognition ............................12 Example of custom screen recognition .........................13 Custom screen recognition using global variables......................14 Accessing javax.servlet classes .............................16 Chapter 3. Creating custom components and widgets ...............17 HATS component tag and attributes ...........................17 Creating a custom host component ...........................20 Extending component classes .............................22 Creating a custom HTML widget ............................23 Extending widget classes ..............................24 Widgets and global rules ..............................24 Registering your component or widget ..........................25 HATS Toolkit support for custom component and widget settings .................26 Chapter 4. Working with Dojo widgets ......................29 Customizing a HATS Dojo widget ............................29 Component settings ...............................31 Widget settings .................................31 HATS Dojo widget customization examples .......................31 Using the Dojo TabContainer widget ...........................40 Using the Dojo TabContainer widget in a HATS Web project ..................40 Using the Dojo TabContainer widget in a HATS portlet project .................44 Chapter 5. Programming in HATS Portlets ....................47 Standard portlets .................................47 Using security .................................47 Extending the Entry portlet .............................49 Running Integration Objects .............................50 Chapter 6. Programming with Integration Objects .................53 A common class for accessing Integration Object information ...................53 Java class hierarchy of Integration Objects .........................54 Integration Object methods ..............................54 Common methods ................................54 Host Access Integration Object methods .........................55 Database Access Integration Object methods .......................57 Specifying Connection Overrides ............................57 © Copyright IBM Corp. 2003, 2015 iii Integration Object chaining ..............................59 Applying XML style sheet processing to Integration Object output .................61 DTD of XML data that is returned by getHPubXMLProperties() method ..............61 DTD of XML data that is returned by getHPubXMLProperties (HPubConvertToTableFormat.xsl) method . 62 Chapter 7. Developing Web services .......................65 Creating traditional (WSDL-based) Web services .......................66 Creating a Bottom-up Web service from Integration Objects ..................66 Creating a Web service from EJB Access Beans.......................68 Testing your Web service with Web Services Explorer ....................68 Creating a Web service client ............................69 Creating a Top-down Web service that includes Integration Objects................70 Programming with Web Services Integration Objects and EJB Access Beans .............70 Updating Web services ..............................71 Web services for JAX-WS runtime considerations and limitations ................72 Creating RESTful Web services .............................72 Creating RESTful service JAX-RS resources ........................73 Updating RESTful service JAX-RS resources .......................75 Customizing RESTful service JAX-RS resource methods ...................75 Handling content ................................77 Customizing the response header ...........................78 HTTP status codes ................................79 JAX-RS RESTful services considerations and limitations ...................79 Chapter 8. Creating and using a HATS EJB application ...............81 Creating a HATS EJB project..............................83 Storing a HATS EJB project in a repository ........................84 Creating EJB Access Beans automatically ........................84 Programming with EJB Access Beans ...........................85 Using EJB Access Bean methods ...........................85 Using EJB Access Beans with Java application clients ....................86 Chapter 9. Integration Objects - advanced topics .................91 Customizing Integration Object Java code .........................91 Choosing Integration Object templates ..........................92 Choosing Integration Object templates for a bidirectional project ................92 Modifying Java coding templates ............................93 Sample modified Integration Object template .......................95 Using Integration Objects in a WebSphere Java EE application ..................96 Using an Integration Object in a Web container (custom servlet or JSP) ..............96 Using an Integration Object in an EJB container (from your own EJB) ...............99 Connection management API .............................101 acquireExistingTransformationConnection ........................102 releaseExistingTransformationConnection ........................102 Chapter 10. Creating plug-ins for Web Express Logon...............103 Creating custom plug-ins for Web Express Logon ......................103 Web Express Logon plug-in interface .........................104 Writing a Network Security plug-in ..........................107 Writing a Credential Mapper plug-in .........................107 Sample Web Express Logon plug-in ..........................108 Encrypting and decrypting plug-in parameter strings ....................108 The DCAS API object...............................108 Chapter 11. Using the HATS bidirectional API...................111 Data Conversion APIs ...............................111 ConvertVisualToLogical ..............................111 ConvertLogicalToVisual ..............................111 Global Variable APIs ................................111 getGlobalVariable ................................112 iv IBM Host Access Transformation Services: Web Application Programmer's Guide getSharedGlobalVariable..............................112 BIDI OrderBean .................................112 BIDI OrderBean methods ..............................113 Appendix A. HATS Toolkit files .........................117 Application file (.hap) ...............................117 <application> tag ................................117 <connections> tag ................................118 <connection> tag ................................118 <eventPriority> tag ...............................118 <event> tag ..................................118 <classSettings> tag ...............................118 <class> tag ..................................118 <setting> tag .................................119 <textReplacement> tag ..............................127 <replace> tag .................................127 <defaultRendering> tag ..............................128 <renderingSet> tag ...............................129 <renderingItem> tag ...............................129 <globalRules> tag ................................131 <rule> tag ..................................131 Connection files (.hco) ...............................134 <hodconnection> tag ...............................134 <otherParameters> tag ..............................139 <classSettings> tag ...............................141 <class> tag ..................................141 <setting> tag .................................141 <poolsettings> tag................................144 <webexpresslogon> tag ..............................145 <userconfig> tag ................................145 Template and transformation files (.jsp)..........................145 Screen combination files (.evnt) ............................146 <combinations> tag ...............................146 <enddescription> tag ...............................146 <navigation> tag ................................147 <screenUp> tag ................................147 <screenDown> tag ...............................147 <keyPress> tag .................................147 <setCursor> tag ................................147 <sendText> ..................................147
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages200 Page
-
File Size-