While editing a message definition, you build its structure as a node model. A message definition can contain two types of nodes: fields and containers. Fields represent data, for example, a postal code. Containers can hold any combination of other containers and fields. After you add or insert fields and containers to a message definition, you can copy and paste them or change their order at any time by dragging and dropping.
Right-click the message (root) node or a container and select New Child|Container or Insert|Container.
A new container is added above the currently selected node.
To move the container to another part of the message definition, drag and drop it to the correct location.
In the Container Properties pane, complete the information using the following table.
When you select options for the Repeat Type, Node Type, and Termination Type fields, most selections reveal one or more subproperties that you must complete as well. Each option's subproperties, if any, are explained in Subproperties and Explanation column.
Container Properties
Container Properties | Options | Subproperties and Explanation | |
---|---|---|---|
Name | For example, ShiptoAddress. NoteThe name must conform to the naming conventions for XML elements and the naming conventions for Java classes. For more information, see Troubleshooting Message Definition Objects. | ||
Optional | Select whether or not this container must occur in each message: | ||
True | This container can be present or absent from a message. | ||
False | Each message has at least one of these containers. | ||
Repeat Type | Select the rule that determines how many containers of this type are expected to occur in each message: | ||
None | This container always occurs once and only once. | ||
Unbounded | This container can occur any number of times or not at all. | ||
Fixed Count | This container occurs X number of times in each message, where X = Instances. | ||
Field Driven | This container appears X number of times, where X = the non-negative integer value of the field specified by Instance Count Field. | ||
Range | This container may appear any number of times between and including X and Y, where X is the positive non-zero integer value of Min and Y is the positive non-zero integer value of Max. | ||
Min | Enter the fewest allowable instances of this container, for example, 1. | ||
Max | Enter the fewest allowable instances of this container, for example, 5. | ||
Node Type | Select whether the node consists of data, a literal tag, or both, and if the data conforms to a specified length: | ||
Container | In the wire format, the container is not identified by a tag. | ||
TaggedContainer | The container is identified by a literal tag, for example, ZIP:. | ||
Tag Value | Click . . . to define the tag that identifies this container. | ||
Group Type | Select the option that describes how this container's fields are arranged: | ||
Ordered | This container contains a set of fields that occur in the same order for every message. When you add fields to this container, the field order must match the actual field order in a message. | ||
Alternative | This container contains two or more fields, but only one of the fields is expected to occur per message. Use this type of container group type to model a field that can be one of several types in any given message. | ||
Termination Type | Define how the end of the container is identified: | ||
None | The end of the container is not marked. | ||
End of Container | The container accepts input until the beginning of the next field or container or until the end of the message. | ||
Delimiter | The end of the container is marked by a literal character string or binary sequence. For example: A semicolon ; | ||
Delimiter Value | Click . . . to set up a delimiter to identify the end of the container. | ||
Fixed Length | For all messages, the container length is defined by a consistent integer value. | ||
Length | Enter the length of the container, for example, 255. | ||
Unit | Select Character if Length is measured in characters or Byte if Length is measured in bytes. | ||
Minimum Length & Delimiter | A minimum number of characters are read from the field, continuing until a delimiter is reached. | ||
Delimiter Value | Click . . . to set up a delimiter to identify the end of the container. | ||
Length | Enter the length of the container, for example, 255. | ||
Unit | Select Character if Length denotes the number of characters or Byte if Length denotes the number of bytes. | ||
Minimum Length & White Space | A minimum number of characters are read from the field, continuing until whitespace data is read, which may include spaces, carriage returns, line feeds, horizontal tabs, or vertical tabs. | ||
Length | Enter the length of the container, for example, 255. | ||
Unit | Select Character if Length is measured in characters or Byte if Length is measured in bytes. | ||
White Space | The end of the container is marked by whitespace data, which can include spaces, carriage returns, line feeds, horizontal tabs, or vertical tabs. |
To make copies of this container, right-click it and select Copy, then Paste.
When finished, select File|Save.
Send your feedback on this help topic to Sybase Tech Pubs: pubs@sybase.com