+ All Categories
Home > Documents > CICS Programming_

CICS Programming_

Date post: 07-Apr-2018
Category:
Upload: mrbaek
View: 232 times
Download: 0 times
Share this document with a friend

of 12

Transcript
  • 8/4/2019 CICS Programming_

    1/12

    2006 IBM Corporation

    Summer University 2006

    Isabel ArnoldIBM Technical Sales zSoftware

    [email protected]

    CICS Applications

    Design and Programming

  • 8/4/2019 CICS Programming_

    2/12

    Summer University 2006

    CICS Application Design and Programming

    Three Tier Application Design

    PresentationLogic

    Business

    Logic

    Data AccessLogic

  • 8/4/2019 CICS Programming_

    3/12

    Summer University 2006

    CICS Application Design and Programming

    CICS Essential Design concepts

    PresentationLogic

    BusinessLogic

    Data AccessLogic

    COMMAREA or CHANNEL

    WB01

    3270

    Pseudoconversational

    programming

    +Program to Program communication

  • 8/4/2019 CICS Programming_

    4/12

    Summer University 2006

    CICS Application Design and Programming

    Basic Mapping Support

    CICS Presentation Logic

    01 CUSTMAP

    02 CustomerName

    02 CustomerAddress

    02 CustomerPhone

    RECEIVE

    SEND

    Type your info.

    Name: Mary

    Address: 123

    Phone: 555_

  • 8/4/2019 CICS Programming_

    5/12

    Summer University 2006

    CICS Application Design and Programming

    Dialog Design Overview

    RECEIVE Menu Screen

    Record InquiryAccount: 1234Name: SmithAmount: $10.00Date: 05/28/01

    MenuEnter account: _____Function code: ___

    MenuEnter account: _1234_Function code: _I_

    MenuEnter account: _____Function code: ___ SEND Menu Screen

    SEND Detail Screen

    RECEIVE Exit Function

    SEND Menu Screen

  • 8/4/2019 CICS Programming_

    6/12

    Summer University 2006

    CICS Application Design and Programming

    EXEC CICSREAD

    FILE ('CLIENTS')INTO (CLNT-REC-AREA)RIDFLD (CLNT-NUMBER)UPDATEEND-EXEC

    CICS Command Syntax

    Here comes a command

    What you want CICS to do

    How CICS should do it

    Language-dependent

    EXEC CICS

    CommandOption (argument)

    Option (argument)

    Delimiter

    import com.ibm.cics.server.ESDS;import com.ibm.cics.server.RecordHolder;

    ESDS acctfile = new ESDS();acctfile.setName("ACCTFILE");RecordHolder record = new RecordHolder();acctfile.read(1, record);

    Different in Java:

    Uses JCICS classes Object oriented

    approach

  • 8/4/2019 CICS Programming_

    7/12

    Summer University 2006

    CICS Application Design and Programming

    CICS Program-to-Program Communication

    CICS supplied P2P COMMAREA based functions:

    EXEC CICS LINK (CICS to CICS, can be remote)

    EXEC CICS XCTL (CICS to CICS)

    ECI call (CICS Universal Client to CICS)

    ECI call (CICS Transaction Gateway to CICS)

    EXCI (z/OS Batch to CICS)

    ProgramLogic

    Program

    Logic

    COMMAREA

    CICS Transaction Server

    SELECT

    TYPE: 564-89712-0

    QUERY UPDATE

    CICSUniversal

    Client

    Workstation

    CICSTransaction

    Gateway

    WebApplication

    Server

    Browser

    Program

    Logic

    COMMAREAor

    CHANNEL

    BATCH

  • 8/4/2019 CICS Programming_

    8/12

    Summer University 2006

    CICS Application Design and Programming

    The Commarea

    A container that holds data

    maximum length is 32Kb

    Passed from one program to another

    same task or not

    same COMMAREA for the request and the reply (if any)

    Empty, partially filled, or full

  • 8/4/2019 CICS Programming_

    9/12

    Summer University 2006

    CICS Application Design and Programming

    Link with Commarea

    MOVE HUGO TO MYCOMMAREA

    EXEC CICS LINK PROGRAM(HELLOPRO")COMMAREA(MYCOMMAREA)

    END-EXEC

    String commarea = HUGO ;

    Program hello = new Program();

    hello.setName(HELLOPRO );

    hello.link(commarea.getBytes());

    ProgramHELLOPROHUGO

  • 8/4/2019 CICS Programming_

    10/12

    Summer University 2006

    CICS Application Design and Programming

    Channels & Containers

    A NAMED group of NAMED CONTAINERs CONTAINER can be seen as a named COMMAREA CONTAINER is not limited in size no limit on the number of CONTAINERs in a CHANNEL data conversion at CONTAINER level CONTAINERs address complex message structure issues

    Passed from one program to another

    Empty or not

    ContainerA

    ContainerB

    ContainerC

    CHANNEL4

  • 8/4/2019 CICS Programming_

    11/12

    Summer University 2006

    CICS Application Design and Programming

    Link with Channel One program / One channel

    One channel / Multiple programs

    The Channel is the interface to a Component

    Program A

    EXEC CICS PUT CONTAINER(EMPLOYEE_INFO')

    FROM(local_variable)

    END-EXEC

    EXEC CICS LINK PROGRAM(PROGRAMB)

    CHANNEL(EMPLOYEE_INFO)

    Program B

    Program A

    EXEC CICS PUT CONTAINER(EMPLOYEE_INFO')

    FROM(local_variable)

    END-EXEC

    EXEC CICS LINK PROGRAM(PROGRAMB)

    CHANNEL(EMPLOYEE_INFO)

    Program CProgram B

    EXEC CICS LINK PROGRAM(PROGRAMC)

    CHANNEL(EMPLOYEE_INFO)

    Employee Inquiry component

  • 8/4/2019 CICS Programming_

    12/12

    Summer University 2006

    CICS Application Design and Programming

    ExecutableCode

    Program Preparation Process

    Pre-translateEXEC CICS

    Linkage Editor

    Compiler

    Translator

    SourceProgram

    pureSource

    OBJfile

    LOADmodule

    ExecutableCode

    Java SourceProgram

    CompilerCompile once

    -Run anywhere


Recommended