Table of Contents

Class IsoIec15434Format06BarCodeMatcher

Namespace
Acuit.Pinpoint.Common.BarCodes
Assembly
Acuit.Pinpoint.Common.dll

A bar code matcher that matches against and extracts numbers from ISO/IEC-15434 format 06 bar codes.

public class IsoIec15434Format06BarCodeMatcher : BarCodeMatcher
Inheritance
IsoIec15434Format06BarCodeMatcher
Inherited Members

Examples

To encode these data items:

Data Identifier Value
P ABCD
S 1234
1P WXYZ

The bar code would be:

[)>␞06␝PABCD␝S1234␝1PWXYZ␞␄

Remarks

ISO/IEC-15434 format 06 bar codes are formatted like this:

[)>␞06␝{DI1}{V1}␝{DI2}{V2}␞␄

Where:

  • ␝ = ASCII GS control character (hex 1D)
  • ␞ = ASCII RS control character (hex 1E)
  • ␄ = ASCII EOT control character (hex 04)
  • {DI1} = the data identifier for the first data item (e.g., S for serial number, P for part number, 1P for vendor part number)
  • {V1} = the value for the first data item
  • {DI2} = the data identifier for the second data item
  • {V2} = the value for the second data item

Note that this example includes two data items, but any number could be included.

Constructors

IsoIec15434Format06BarCodeMatcher(IReadOnlyCollection<KeyValuePair<string, string>>)

Initializes a new instance of the IsoIec15434Format06BarCodeMatcher class.

public IsoIec15434Format06BarCodeMatcher(IReadOnlyCollection<KeyValuePair<string, string>> dataIdToNumberIds)

Parameters

dataIdToNumberIds IReadOnlyCollection<KeyValuePair<string, string>>

The data items that must exist in the bar code, specified as key-value pairs where the key specifies the ISO/IEC-15434 format 06 data identifier and the value specifies the identifier of the number to which to extract the data item value.

Remarks

Note that for the bar code to match, all specified data items must exist in the bar code.

Exceptions

ArgumentNullException

dataIdToNumberIds is null.

Properties

DataIdToNumberIds

Gets the data items that must exist in the bar code.

public IReadOnlyCollection<KeyValuePair<string, string>> DataIdToNumberIds { get; }

Property Value

IReadOnlyCollection<KeyValuePair<string, string>>

NumberIds

Gets the list of number identifiers that this bar code matcher can capture.

public override IReadOnlyList<string> NumberIds { get; }

Property Value

IReadOnlyList<string>

Methods

TryMatchBarCode(string, out IReadOnlyDictionary<string, string>?)

Tries to match a bar code.

public override bool TryMatchBarCode(string barCode, out IReadOnlyDictionary<string, string>? numbers)

Parameters

barCode string

The bar code content.

numbers IReadOnlyDictionary<string, string>

On return, if the bar code content matched, the numbers found in the bar code as a dictionary keyed by their number identifiers (case-sensitive); otherwise, null.

Returns

bool

true if the bar code matches; othersise, false.

Exceptions

ArgumentNullException

barCode is null.