Designing Custom Encoders

Specifying Pattern Alignment

The align property supplements the match property, specifying criteria on which to base the match. The default value is blind; if this is specified, the match property has no meaning.

Figure 5 Align Property Menu

Figure described in content.

Table 7 Align Parameter Options

Option 

Description 

blind 

Always performs a match (pass-through). Any value set for the Match property is ignored. This is the default value.

exact 

When an input byte sequence exactly matches the specified byte pattern (for example, [abc]), the decode method matches the field to the input byte sequence.

begin 

When the leading bytes of an input byte sequence match the value set for the Match property (for example, [abc......]), the decode method matches the field to the input byte sequence.

final 

When the trailing bytes of an input byte sequence match the value set for the Match property (for example, [......abc]), the decode method matches the field to the input byte sequence.

inter 

When the input byte sequence contains a byte pattern that includes the value set for the Match property, (for example, [...abc...]), the decode method matches the field to the input byte sequence.

super 

When an input byte sequence is a subsequence of the value set for the Match property (for example, [bc]), the decode method matches the field to the input byte sequence.

oneof 

If the value set for the Match property is a repeating pattern of the form <separator><value>... (for example, [\mon\wed\fri]), and the input byte sequence contains a byte pattern that matches one of the <value> entries (for example, [wed]), the decode method matches the field to the input byte sequence.

regex 

When an input byte sequence exactly matches the regular expression specified in the Match property, the decode method matches the field to the input byte sequence. The Alignment property is automatically set to regex when the Fixed Length Type property is specified as determined by regex match.


Note –

The value entered for the match property is interpreted as a Latin1 string, rather than following the specified encoding.