|
| Copyright © Cloud Software Group, Inc. All Rights Reserved |
This reference is therefore mainly for developers who perform a custom configuration using Generic Adapter Configuration.
•
•
• When you launch TIBCO Designer, the project tree always includes an AESchemas folder immediately under the top-level folder.The AESchemas folder is the repository for all schema data used by all applications in your project.
•
• When you configure a custom adapter, you create schemas inside the AESchemas folder. You then add schema references to the services your adapter provides. Some examples are given in this chapter.When you select an item inside the AESchemas folder, for example, a Classes folder or an individual class resource in the project tree, the Adapter Schema palette is displayed in the palette panel.You use this palette to define schema for your adapter. See Defining Custom Adapter Schema for an example.A Generic Class resource can be used for these purposes:
•
1.
2. Drag a Folder resource into the ae folder displayed in the design panel and name it appropriately for your adapter.
3. Drag an AESchema resource into the folder. Open the AESchema resource and select its Classes folder.
4. In the palette panel, select the Generic Class icon and drag it into the design panel.
5.
4. Click Apply.
2. Select the class to which you want to add the attribute, or drag a Generic Class into the design panel and choose Schema as the type.
4. Click Apply.See How TIBCO Applications Use Schema Data for more information.To add an attribute whose value must be a union, you must first have defined one or more Union resources. See Unions:
2. Select the class to which you want to add attributes, or drag a Generic Class into the design panel and choose Schema as the type.
4. Click Apply.
2. Select the class to which you want to add attributes, or drag a Generic Class into the design panel and choose Schema as the type.
5. Click Apply.
2. Select the class to which you want to add attributes, or drag a Generic Class into the design panel and choose Schema as the type.The values you can choose from are the types available as part of the Adapter SDK class library. See the TIBCO Adapter SDK Programmer’s Guide for information on the mapping of these types to Java or C++ types.
1.
2. Drag a Folder resource into the ae folder displayed in the design panel and name it appropriately for your adapter.
3. Drag an AESchema resource into the folder. Open the AESchema resource and select its Classes folder.
4. In the palette panel, select the Generic Class icon and drag it into the design panel.
5.
6. You can now add operations to the class (see Adding Operations to an Operation Class). If you are using palette view, you must select the appropriate palette before you can proceed.
To add operations to an Operation class, follow these steps:
1. Select the Operation resource in the project tree.
2. From the palette panel, drag the Operation icon into the design panel, then:
b. Click Browse and select the resource that specifies the return type. It could, for example, be a resource in the AESchema/ae/Scalars folder or a predefined class.
c. Click the One Way check box if this is a one way operation.
3. Select the parameters folder and drag resources representing the parameter type into the design panel. For example, assume you want to specify an input parameter of type string:
a. Drag a Generic Scalar into the design panel.
b. In—In parameter. Client can set the value and invoke the operation.In/Out—Both client and server can set the value.Out—Only server can set the value and send the reply back to client.
c. Click Apply.
4. Select the Exceptions folder and drag a resource representing the exception type into the design panel. For an error code, you could use a scalar with the appropriate type. You could also specify a class, as follows:
a. Drag a Generic Class into the design panel.
b. Specify a name and click Browse to select a class.
c. Choose AESchemas/ae/MAdvisoryDocument to indicate this exception returns an MAdvisoryDocument instance.
d. Click Apply.
1.
2. Drag a Folder resource into the ae folder displayed in the design panel and name it appropriately for your adapter.
3. Drag an AESchema resource into the folder. Open the AESchema resource and select its Classes folder.
4. In the palette panel, select the Generic Class icon and drag it into the design panel.
5.
6. Select the Operation Schema class in the project tree. From the palette panel, drag an Operation into the design panel.Returns: Click Browse and select the return type for the operation. It could, for example, be a resource in the AESchema/ae/Scalars folder or a predefined class.
8. Select the Parameters folder of the operation. From the project tree, drag in the resources representing the parameter types. See Defining Operation Parameters.
9. Select the Exceptions folder of the operation. From the project tree, drag in the resources representing the exception types.Use this folder to drag in resources representing the exception types, as discussed in the following sections. See Defining Exception Parameters.
3. Select a class in the project tree and drag it into the design panel, or click Browse and find the class you want to use.
5. Click Apply.
3. Select a sequence in the project tree and drag it into the design panel, or click Browse and find the class you want to use.
5. Click Apply.
3. Select a scalar in the project tree and drag it into the design panel, or click Browse and find the class you want to use.
5. Click Apply.
3. Select a union in the project tree and drag it into the design panel, or click Browse and find the class you want to use.
5. Click Apply.
4. Click Apply.Within TIBCO Designer, the term Scalar refers to a primitive object that describes a data type, such as int, long, char, byte, and date. You select the appropriate folder (for example, ae or sql) and object to determine what kind of primitive data type describes the object and which attributes must therefore be set.
In addition, you can work with parameterized primitive data types (for example, ae/fixed, ae/binary, ae/char), where you can derive an infinite number of types from a base type by changing various data type attributes. You can use these types, for example, to create a bounded binary or bounded char type. If there is a base data type, then it will be pre-loaded, but you are required to create any other instances as you need them, just as you would for sequence types.
2.
1. In the project tree panel, select the Classes folder.
2. In the palette panel, select a Generic Class and drag it into the design panel.
3. In the configuration panel, select Schema as the class type.
4. To add a scalar attribute, select the new schema class, then drag a Generic Scalar from the palette panel into the design panel.
6. Click Apply.Define one or more Union objects as follows:
1. Select the Union folder.
2. From the palette panel, drag a Generic Union into the design panel.
3.
2. From the project tree, drag an existing class, for example, an MBusinessDocument into the design panel.TIBCO Designer creates a reference to MBusinessDocument and makes it the first union member.
3. Drag a second class, for example, an MAdvisoryDocument into the design panel.If you now add the union as an attribute to a schema class and assign that schema to an endpoint, the endpoint will only accept data of type MBusinessDocument or MAdvisoryDocument.
1. Select a Union in the project tree.
1. Select the Sequence folder.
2. From the palette panel, drag a Generic Sequence into the design panel.Both ends of an association can have a multiplicity. For example, a 1 to 1 relation has multiplicity = 1 on both ends. One to n (i.e. unlimited) has 1 at one end and -1 (unlimited) on the other. In these cases, there is only one multiplicity number and minMultiplicity and maxMultiplicity will be equal.In rather rare cases, you would specify a different minimum and maximum. One example given in the "UML Distilled" book is that a car can have 2 to 4 doors. So in this case the "car" end of the association would have multiplicity 1 and the "door" end would have minMultiplicity = 2 and maxMultiplicity = 4.
|
| Copyright © Cloud Software Group, Inc. All Rights Reserved |