WebSphere Message Brokers
File: ad02860_
Writer: Terry Cowling

Task topic

This build: July 31, 2007 21:22:12

Setting value constraints

Before you start:

You must have completed the following tasks:

Value constraints are usually associated with a simple type; they refine a simple type by defining limits on the values which the simple type can represent. To set the value constraints associated with a simple type:

  1. Switch to the Broker Application Development perspective.
  2. In the Outline view, click the simple type you are updating. If the Outline view is not visible, from the workbench menu, click Window> Show View> Outline.
  3. Display the Properties tab of the Message Definition Editor by clicking Properties in the bottom left corner of the editor area. The Properties Hierarchy displays the following nodes:
    • Logical Properties
    • Physical Properties
    • Documentation
  4. In the Properties Hierarchy under Logical Properties click Value Constraints. This displays the current value constraints settings for the selected simple type in the Details pane.
    Tip: If Value Constraints is not in view, expand Logical Properties by clicking +.
  5. Set the value constraints for the selected simple type by making the appropriate changes to the information shown in the Details pane.

Setting an enumeration

An enumeration restricts which values can be set for the value constraint. For example, "ABC" and "123". Use this section to create a list of fixed values that the associated type must match.

To set an enumeration:

  1. Click Add to the right of the Enumerations field. This adds an enumeration that has a default enumeration (for example enumeration1).
  2. Type the data that you want to set for this value constraint.
  3. Press Enter on your keyboard.
  4. Repeat the above steps for each enumeration that you are adding.

Setting a pattern

Set a pattern to indicate that the value constraint defines a string used as a regular expression that must be matched by the data in the associated type. The regular expression syntax supported is a subset of XML Schema regular expressions.

See Regular expression syntax for a list of supported regular expression syntax elements.

To set a pattern:

  1. Select Add to the right of the Patterns field. This adds a pattern that has a default pattern (for example pattern1) and is in update mode.
  2. Type the data that you want to set for this value constraint.
  3. Press Enter on your keyboard.
  4. Repeat the above steps for each pattern that you are adding.
Related tasks
Deleting objects
Notices | Trademarks | Downloads | Library | Support | Feedback

Copyright IBM Corporation 1999, 2007Copyright IBM Corporation 1999, 2007. All Rights Reserved.
This build: July 31, 2007 21:22:12

ad02860_ This topic's URL is: