Importing an SNA Custom Handshake Class

Similar documents
Defining Constants and Variables for Oracle Java CAPS Environments

JavaFX. JavaFX System Requirements Release E

Copyright 1998, 2009, Oracle and/or its affiliates. All rights reserved.

Importing an SNA Custom Handshake Class

Configuring Oracle Java CAPS Master Index (Repository) Connectivity and Environments

Designing with Oracle Java CAPS Communication Adapters

1 Understanding the Cross Reference Facility

Oracle Hospitality OPERA Exchange Interface Cloud Authentication. October 2017

New Features in Primavera Professional 15.2

Report Management and Editor!

Oracle Hospitality Query and Analysis Languages and Translation Configuration Guide. March 2016

JD Edwards EnterpriseOne. Overview. Prerequisites. Web Client for ipad Quick Start Guide Release 8.98 Update 4, Service Pack 5

Oracle Enterprise Manager Ops Center

Recipe Calculation Survey. Materials Control. Copyright by: MICROS-FIDELIO GmbH Europadamm 2-6 D Neuss Date: August 21 st 2007.

Oracle Enterprise Manager

Oracle Enterprise Manager Ops Center. Introduction. What You Will Need

PeopleSoft Fluid Required Fields Standards

Oracle Utilities Advanced Spatial and Operational Analytics

Oracle Hospitality Suite8 Export to Outlook User Manual Release 8.9. July 2015

Oracle Enterprise Manager Ops Center. Introduction. What You Will Need. Hardware and Software Configuration

What s New for Cloud at Customer What's New for the Cloud Services on Oracle Cloud at Customer New Documentation for Oracle Cloud at Customer

Oracle Communications Configuration Management

Oracle Tuxedo Mainframe Adapter for SNA

Oracle Enterprise Manager Ops Center. Introduction. What You Will Need. Installing and Updating Local Software Packages 12c Release

PeopleSoft Fluid Icon Standards

JavaFX. JavaFX System Requirements Release E

Oracle Retail MICROS Stores2 Functional Document Sales - Receipt List Screen Release September 2015

JavaFX. JavaFX 2.2 System Requirements Release 2.2 E

Oracle Enterprise Single Sign-on Logon Manager How-To: Configuring ESSO-LM Event Logging with Microsoft SQL Server 2005 Release

Oracle Enterprise Manager. 1 Introduction. System Monitoring Plug-in for Oracle Enterprise Manager Ops Center Guide 11g Release 1 (

Materials Control. Account Classes. Product Version Account Classes. Document Title: Joerg Trommeschlaeger

Oracle Utilities Work and Asset Management Integration to Primavera P6 Enterprise Project Portfolio Management

Oracle Banking Channels Bank User Base

Oracle Hospitality MICROS Commerce Platform Release Notes Release Part Number: E December 2015

Oracle Enterprise Manager Ops Center. Introduction. Creating Oracle Solaris 11 Zones Guide 12c Release 1 ( )

Oracle Enterprise Manager Ops Center. Introduction. What You Will Need. Creating vservers 12c Release 1 ( )

Oracle Hospitality Cruise Shipboard Property Management System Topaz Signature Device Installation Guide Release 8.00 E

Oracle WebCenter Portal. Starting Points for Oracle WebCenter Portal Installation

JD Edwards EnterpriseOne Licensing

Database Change Reference Release 6.3

Oracle Payment Interface Installation and Reference Guide Release E April 2018

Oracle Fusion Middleware Oracle Stream Analytics Release Notes. 12c Release ( )

What s New for Oracle Cloud Stack Manager. Topics: July Oracle Cloud. What's New for Oracle Cloud Stack Release

Oracle Exadata Healthchecks Plug-in Contents

Using SOAP Message Handlers

Export generates an empty file

Oracle Utilities Opower Custom URL Configuration

Oracle Database Firewall. 1 Downloading the Latest Version of This Document. 2 Known Issues. Release Notes Release 5.

Oracle Utilities Work and Asset Management

Customer Service Training Activities Created on 10/10/2011 3:33:00 PM. FSU Service Center. Quick Reference Guide v.

Oracle Retail MICROS Stores2 Functional Document Stores2 for Portugal Disaster Recovery Release

BAA Oracle EBS R12.1 isupplier Portal Created on 11/26/2012 3:18:00 PM

OKM Key Management Appliance

Oracle. Field Service Cloud Using the Parts Catalog

Oracle Linux. UEFI Secure Boot Signing Key Update Notice

Materials Control Recipe Reduction based on Article Defaults

Managing Zone Configuration

Introduction to Auto Service Request

General Security Principles

Oracle Hospitality RES 3700 Server Setup Guide Release 5.5 E May 2016

Oracle Hospitality BellaVita Hardware Requirements. June 2016

Oracle Cloud What's New for Oracle WebCenter Portal Cloud Service

Oracle Argus Safety. 1 Configuration. 1.1 Configuring a Reporting Destination for the emdr Profile. emdr Best Practices Document Release 8.0.

Oracle Communications Policy Management Configuring NetBackup for Upgrade Method of Procedure

Oracle Enterprise Manager Ops Center

Oracle Communications Order and Service Management. OSM New Features

Oracle Enterprise Manager Ops Center. Introduction. What You Will Need

New Features in Primavera P6 16.2

Microsoft Active Directory Plug-in User s Guide Release

Oracle Hospitality Suite8 XML Export of Invoice Data for Hungarian Tax Authority Release and Higher E November 2016

Oracle Hospitality BellaVita Adding a New Language Release 2.7. September 2015

Oracle Java CAPS Database Binding Component User's Guide

Materials Control. Installation MC POSWebService. Product Version Joerg Trommeschlaeger. Date: Version No. of Document: 1.

Oracle mymicros.net, icare, myinventory and mylabor Self Host Release Notes Release v April 2015

Oracle Simphony Venue Management (SimVen) Installation Guide Release Part Number: E

Oracle Utilities Work and Asset Management

Oracle Enterprise Data Quality for Product Data

Security Guide Release 4.0

Oracle Utilities Meter Data Management Release Utility Reference Model Maintain Generic Usage Subscription

JavaFX. Oracle JavaFX Applying Transformations in JavaFX Release 2.1 E

Oracle Utilities Customer Self Service

Oracle Fusion Middleware. 1 Contents. 2 Where to Find Oracle WebLogic Tuxedo Connector Samples. 3 Configuring the Oracle WebLogic Tuxedo Connector

Taleo Enterprise Deep Linking Configuration Guide Release 17

Oracle Utilities Work and Asset Cloud Service End-User Provisioning Guide


Oracle Hospitality Cruise Meal Count System Security Guide Release 8.3 E

Oracle Endeca Commerce Compatibility Matrix

Oracle Utilities Work and Asset Management

Oracle Enterprise Manager Ops Center. Overview. What You Need. Create Oracle Solaris 10 Zones 12c Release 3 ( )

Oracle Endeca Guided Search Compatibility Matrix

Oracle Communications Convergent Charging Controller. Sample Message Flows Reference Guide Release 6.0.1

PeopleSoft Fluid Related Action Standards

Microsoft Internet Information Services (IIS) Plug-in User s Guide Release

SunDual Port 4x QDR IB Host Channel Adapter PCIe ExpressModule

Oracle Hospitality Simphony Venue Management Release Notes Release 3.9 E March 2017

Spend less on file attachment storage space Reliably back up your data or file attachments Use your OpenAir data in your reporting tools

User Manual. Materials Control. Production Tool. Copyright by: MICROS-FIDELIO GmbH Europadamm 2-6 D Neuss Date: March 2012.

Materials Control. Purchase Orders Internal Attachments. Product Version: Attachments Joerg Trommeschlaeger.

Oracle Enterprise Manager Ops Center. Introduction. Creating Oracle Solaris 11 Zones 12c Release 2 ( )

StorageTek Enterprise Library Software

Transcription:

Importing an SNA Custom Handshake Class Part No: 821 2599 March 2011

Copyright 2008, 2011, Oracle and/or its affiliates. All rights reserved. License Restrictions Warranty/Consequential Damages Disclaimer This software and related documentation are provided under a license agreement containing restrictions on use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify, license, transmit, distribute, exhibit, perform, publish or display any part, in any form, or by any means. Reverse engineering, disassembly, or decompilation of this software, unless required by law for interoperability, is prohibited. Warranty Disclaimer The information contained herein is subject to change without notice and is not warranted to be error-free. If you find any errors, please report them to us in writing. Restricted Rights Notice If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on behalf of the U.S. Government, the following notice is applicable: U.S. GOVERNMENT RIGHTS Programs, software, databases, and related documentation and technical data delivered to U.S. Government customers are "commercial computer software" or "commercial technical data" pursuant to the applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use, duplication, disclosure, modification, and adaptation shall be subject to the restrictions and license terms set forth in the applicable Government contract, and, to the extent applicable by the terms of the Government contract, the additional rights set forth in FAR 52.227-19, Commercial Computer Software License (December 2007). Oracle America, Inc., 500 Oracle Parkway, Redwood City, CA 94065. Hazardous Applications Notice This software or hardware is developed for general use in a variety of information management applications. It is not developed or intended for use in any inherently dangerous applications, including applications that may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this software or hardware in dangerous applications. Trademark Notice Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. Intel and Intel Xeon are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Opteron, the AMD logo, and the AMD Opteron logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered trademark of The Open Group in the United States and other countries. Third Party Content, Products, and Services Disclaimer This software or hardware and documentation may provide access to or information on content, products, and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly disclaim all warranties of any kind with respect to third-party content, products, and services. Oracle Corporation and its affiliates will not be responsible for any loss, costs, or damages incurred due to your access to or use of third-party content, products, or services. 120126@25097

Contents Importing an SNA Custom Handshake Class... 5 Adding a Custom Handshake Class to a Project...5 Configuring the Adapter for a Custom Handshake Class...5 Importing a Custom Handshake Class into a Project...9 Implementing an SNA Custom Handshake Class... 12 Sample Code for Inbound Mode... 12 Sample Code for Outbound Mode... 13 3

4

Importing an SNA Custom Handshake Class This document provides links to conceptual information on how to import an SNA Custom Handshake Class. It includes the following steps: Adding a Custom Handshake Class to a Project on page 5 Implementing an SNA Custom Handshake Class on page 12 Adding a Custom Handshake Class to a Project To use a custom handshake class with the SNA Adapter, you need to configure the Adapter by specifying the class name. You also need to import the file into the SNA Project, and if you are using it in a Java Collaboration Definition, you need to import it into the Collaboration as well. Perform the following steps to use a custom handshake class: Configuring the Adapter for a Custom Handshake Class on page 5 Importing a Custom Handshake Class into a Project on page 9 Before you perform these steps, create the custom class and make it available to the NetBeans IDE. Configuring the Adapter for a Custom Handshake Class In order for the SNA Adapter to know which custom handshake class to use, you need to specify the class name in the Adapter properties of the Connectivity map. 5

Adding a Custom Handshake Class to a Project 1 2 3 To Configure the Adapter In the NetBeans IDE, expand the Project containing the SNA Adapter until the Connectivity Map is visible. Open the Connectivity Map in the Connectivity Map Editor. To import the custom handshake class for the inbound Adapter, double-click the inbound SNA Adapter icon. 6 Importing an SNA Custom Handshake Class March 2011

Adding a Custom Handshake Class to a Project The SNA Adapter Properties Editor appears, displaying the default properties for the inbound Adapter. 4 Edit the Custom Handshake Class Name property in the Properties Editor and click OK. For the sample code provided with the Adapter, enter com.stc.connector.snalu62.api.snacustomerhandshakeimplsampleaccept. Importing an SNA Custom Handshake Class 7

Adding a Custom Handshake Class to a Project 5 To import the custom handshake class for the outbound Adapter, double-click the outbound SNA Adapter icon. The SNA Adapter Properties Editor appears, displaying the default properties for the outbound Adapter. 6 Edit the Custom Handshake Class Name property in the Properties Editor and click OK. For the sample code provided with the Adapter, enter com.stc.connector.snalu62.api.snacustomerhandshakeimplsampleinitialize. 8 Importing an SNA Custom Handshake Class March 2011

Adding a Custom Handshake Class to a Project 7 Redeploy your project. Importing a Custom Handshake Class into a Project In order to use a custom class in a Project and a Java Collaboration Definition (JCD), you need to package the class into a JAR file and then import the file into both the Project and the JCD. 1 2 To Import a Custom Handshake Class Prepare a JAR file that includes your built class. From the NetBeans Projects window, right-click the sample Project and select Import > File. The Import Files window appears. 3 4 Navigate to the JAR file and click Select. The selected JAR file appears in the Selected Import Files pane at the bottom of the Import Files window. Click Import. The selected JAR file appears in the Project tree under the project you selected. Importing an SNA Custom Handshake Class 9

Adding a Custom Handshake Class to a Project 5 Do the following to import the file into a JCD: a. Open the JCD in the Collaboration Editor. b. In the Collaboration Editor toolbar, click the Import JAR file icon. The Add/Remove JAR Files window appears. c. Click Add, navigate to and select the JAR file, and then click Import. The selected JAR file appears in the Imported JAR Files pane. 10 Importing an SNA Custom Handshake Class March 2011

Adding a Custom Handshake Class to a Project d. Click Close on the Add/Remove JAR Files window. The selected JAR file appears under the JCD in the Projects window. Note If you make any changes to the class, repeat the previous steps. Sample Handshake Class The Java Collaboration can handle the SNA connection completely using the default class that is provided with the Adapter, com.stc.connector.snalu62.api.snacustomerhandshakeimplsampledummy. This class has been implemented in the SNA Adapter. The sample code for this custom class is shown below: package com.stc.connector.snalu62.api; import com.stc.connector.logging.logfactory; import com.stc.connector.logging.logger; import com.stc.connector.snalu62.exception.snaapplicationexception; /** * This is a sample class to implement the interface SNACustomerHandshake. * It implements a dummy handshake. That is, the method startconversation() does not perform a function. * No SNA conversation is established inside this implementation class. You should establish the SNA conversation manually (e.g. in the java Collaboration). public class SNACustomerHandshakeImplSampleDummy implements SNACustomerHandshake { public static final String version = "cvs $Revision: 1.1.2.2 $ $Date: 2005/11/10 21:40:15 $"; private Logger logger = LogFactory.getLogger ("STC.eWay.SNALU62." + getclass().getname()); /** * Constructor * public SNACustomerHandshakeImplSampleDummy() { super(); /** * @see com.stc.connector.snalu62.api.snacustomerhandshake#startconversation (com.stc.connector.snalu62.api.snacpiccalls) public void startconversation(snacpiccalls cpic) throws SNAApplicationException { logger.info("snacustomerhandshakeimplsampledummy.startconversation(): Done nothing here."); Importing an SNA Custom Handshake Class 11

Implementing an SNA Custom Handshake Class Implementing an SNA Custom Handshake Class To further utilize the capabilities of the SNA Adapter, you can implement a custom handshake class in a deployed Project. After the default Collaboration is generated, you can then modify the Collaboration to suit your application s needs. While you need to write your own code for both Inbound and Outbound SNA modes, the following code is also provided as the source for the class that is implemented in the SNA adapter. Sample Code for Inbound Mode package com.stc.connector.snalu62.api; import com.stc.connector.logging.logfactory; import com.stc.connector.logging.logger; import com.stc.connector.snalu62.exception.snaapplicationexception; /* * This is a sample class to implement the interface SNACustomerHandshake. * It implements a simple Accept_Conversation scenario for windows platform. public class SNACustomerHandshakeImplSampleAccept implements SNACustomerHandshake { public static final String version = "cvs $Revision: 1.1.2.1.2.2 $ $Date: 2005/11/10 21:40:15 $"; private Logger logger = LogFactory.getLogger("STC.eWay.SNALU62. " + getclass().getname()); private String logmsg; /** * Constructor * public SNACustomerHandshakeImplSampleAccept() { super(); /** * @see com.stc.connector.snalu62.api.snacustomerhandshake#startconversation (com.stc.connector.snalu62.api.snacpiccalls) public void startconversation(snacpiccalls cpic) throws SNAApplicationException { try { //do whatever checking logics before/after the following CPIC call on your desires cpic.cmsltp(); //do whatever checking logics before/after the following CPIC call on your desires cpic.cmaccp(); if (!cpic.getconversationattributes().returncodeis(0) && // 0: CM_OK!cpic.getConversationAttributes().returnCodeIs(35)) { //35: CM_OPERATION_INCOMPLETE logmsg = "SNACustomerHandshakeImplSampleAccept.startConversation(): The return code is <" + cpic.getconversationattributes().getreturncode() 12 Importing an SNA Custom Handshake Class March 2011

Implementing an SNA Custom Handshake Class + ">."; logger.error(logmsg); throw new SNAApplicationException(logMsg); if (cpic.getconversationattributes().returncodeis(35)) { //35: CM_OPERATION_INCOMPLETE logger.info("snacustomerhandshakeimplsampleaccept.startconversation(): About to call cmwait..."); //do whatever checking logics before/after the following CPIC call on your desires cpic.cmwait(); if (!cpic.getconversationattributes().returncodeis(0)!cpic.getconversationattributes().convreturncodeis(0)) { // 0: CM_OK logmsg = "SNACustomerHandshakeImplSampleAccept.startConversation(): The return_code is <" + cpic.getconversationattributes().getreturncode() + "> and the conversation_return_code is <" + cpic.getconversationattributes().getconvreturncode() + ">. SNA conversation is not established."; logger.error(logmsg); throw new SNAApplicationException(logMsg); //do whatever other logics on your desires here //... catch (Exception e) { logmsg = "SNACustomerHandshakeImplSampleAccept.startConversation(): Failed. Got exception [" + e.tostring() + "]."; logger.error(logmsg, e); throw new SNAApplicationException(logMsg, e); Note The above code has been wrapped for display purposes. Sample Code for Outbound Mode package com.stc.connector.snalu62.api; import com.stc.connector.logging.logfactory; import com.stc.connector.logging.logger; import com.stc.connector.snalu62.exception.snaapplicationexception; /** * This is a sample class to implement the interface SNACustomerHandshake. * It implements a simple Initialize_Conversation scenario for windows platform. Importing an SNA Custom Handshake Class 13

Implementing an SNA Custom Handshake Class public class SNACustomerHandshakeImplSampleInitialize implements SNACustomerHandshake { public static final String version = "cvs $Revision: 1.1.2.1.2.2 $ $Date: 2005/11/10 21:40:15 $"; private Logger logger = LogFactory.getLogger("STC.eWay.SNALU62." + getclass(). getname()); private String logmsg; /** * Constructor * public SNACustomerHandshakeImplSampleInitialize() { super(); /** * @see com.stc.connector.snalu62.api.snacustomerhandshake#startconversation (com.stc.connector.snalu62.api.snacpiccalls) public void startconversation(snacpiccalls cpic) throws SNAApplicationException { try { //do whatever checking logics before/after the following CPIC call on your desires cpic.cminit(); //do whatever checking logics before/after the following CPIC call on your desires cpic.cmssl(); //do whatever checking logics before/after the following CPIC call on your desires cpic.cmallc(); if (!cpic.getconversationattributes().returncodeis(0)) { // 0: CM_OK logmsg = "SNACustomerHandshakeImplSampleInitialize. startconversation(): The return_code is <" + cpic.getconversationattributes().getreturncode() + ">. SNA conversation is not established."; logger.error(logmsg); throw new SNAApplicationException(logMsg); //do whatever other logics on your desires here //... catch (Exception e) { logmsg = "SNACustomerHandshakeImplSampleInitialize.startConversation(): Failed. Got exception [" + e.tostring() + "]."; logger.error(logmsg, e); throw new SNAApplicationException(logMsg, e); 14 Importing an SNA Custom Handshake Class March 2011

Implementing an SNA Custom Handshake Class Note The above code has been wrapped for display purposes. Importing an SNA Custom Handshake Class 15

16