C# Class EdiFabric.Sdk.EdiToObject.ConsoleApplication.X12Samples

X12Stream reads item by item from the EDI file stream. The final structure looks like this: ISA GS Message or ParsingException ... (the rest of the messages or errors)... GE IEA ... (the rest of the interchanges) ...
Afficher le fichier Open project: DonZoeggerle/ediFabric.Sdk.EdiToObject

Méthodes publiques

Méthode Description
AccessInterchangeSegments ( ) : void

Get the interchange header and trailer as typed objects.

HandleErrors ( ) : void

Extract all of the errors. The framework does not raise errors. Instead it contains the errors in ParsingException items. This allows the stream to not block, should a message error is raised.

ParseAll ( ) : void

Reads through all items - messages, control segments and errors. Reads the whole stream altogether.

ParseAllStreaming ( ) : void

Reads through all items - messages, control segments and errors. Reads an item at a time.

ParseWithCustomEncoding ( ) : void

Parse with custom encoding. The default encoding is Encoding.Default .

ParseWithExplicitRulesAssemblyName ( ) : void

Parse with rules assembly name. Can be used if assembly name was not set in the .config or if the rules classes are spread across multiple assemblies.

ParseWithNonDefaultClass ( ) : void

Parse with custom namespace prefix. All classes can have custom namespace prefix, e.g. everything before the last part (starting with .X12) can be customized. Can be used if multiple versions of the same transaction set need to be used.

PullDifferentMessageTypes ( ) : void

Extract only certain messages. EDI files can contain multiple groups with each group containing different message types. Although all will be parsed (if a rules class exist otherwise an error item will be created), only a subset can be pulled out.

Method Details

AccessInterchangeSegments() public static méthode

Get the interchange header and trailer as typed objects.
public static AccessInterchangeSegments ( ) : void
Résultat void

HandleErrors() public static méthode

Extract all of the errors. The framework does not raise errors. Instead it contains the errors in ParsingException items. This allows the stream to not block, should a message error is raised.
public static HandleErrors ( ) : void
Résultat void

ParseAll() public static méthode

Reads through all items - messages, control segments and errors. Reads the whole stream altogether.
public static ParseAll ( ) : void
Résultat void

ParseAllStreaming() public static méthode

Reads through all items - messages, control segments and errors. Reads an item at a time.
public static ParseAllStreaming ( ) : void
Résultat void

ParseWithCustomEncoding() public static méthode

Parse with custom encoding. The default encoding is Encoding.Default .
public static ParseWithCustomEncoding ( ) : void
Résultat void

ParseWithExplicitRulesAssemblyName() public static méthode

Parse with rules assembly name. Can be used if assembly name was not set in the .config or if the rules classes are spread across multiple assemblies.
public static ParseWithExplicitRulesAssemblyName ( ) : void
Résultat void

ParseWithNonDefaultClass() public static méthode

Parse with custom namespace prefix. All classes can have custom namespace prefix, e.g. everything before the last part (starting with .X12) can be customized. Can be used if multiple versions of the same transaction set need to be used.
public static ParseWithNonDefaultClass ( ) : void
Résultat void

PullDifferentMessageTypes() public static méthode

Extract only certain messages. EDI files can contain multiple groups with each group containing different message types. Although all will be parsed (if a rules class exist otherwise an error item will be created), only a subset can be pulled out.
public static PullDifferentMessageTypes ( ) : void
Résultat void