├── .gitignore ├── EdiEngine.Common ├── Definitions │ ├── MapBaseDataElement.cs │ ├── MapBaseEntity.cs │ ├── MapCompositeDataElement.cs │ ├── MapLoop.cs │ ├── MapSegment.cs │ └── MapSimpleDataElement.cs ├── EdiEngine.Common.csproj ├── Enums │ ├── DataType.cs │ └── RequirementDesignator.cs └── SyntaxNotes │ ├── ConditionalSyntaxNote.cs │ ├── ExclusionSyntaxNote.cs │ ├── ListConditionalSyntaxNote.cs │ ├── PairedSyntaxNote.cs │ ├── RequiredSyntaxNote.cs │ ├── SyntaxNote.cs │ └── SyntaxNoteFactory.cs ├── EdiEngine.Tests ├── AckBuilderTests.cs ├── DataElementValidationTests.cs ├── EdiEngine.Tests.csproj ├── EdiReaderTests.cs ├── EdiWriterTests.cs ├── JsonReadWriteTests.cs ├── Maps │ ├── M_001.cs │ └── M_940.cs ├── Segments │ └── Segments.cs ├── SyntaxNoteTests.cs ├── TestData │ ├── 001.Fake.Composite.json │ ├── 001.Fake.Composite.xml │ ├── 850.Composite.SLN.OK.edi │ ├── 850.OK.edi │ ├── 850.SyntaxNotes.ERR.edi │ ├── 856.Crossdock.OK.edi │ ├── 856.Crossdock.OK.json │ ├── 856.Crossdock.OK.xml │ ├── 940.2.OK.edi │ ├── 940.ERR.json │ ├── 940.ERR.xml │ ├── 940.OK.edi │ ├── 940.OK.json │ ├── 940.OK.xml │ ├── 940.W05.Only.edi │ ├── 940_Failed_SE01.edi │ ├── AckTest.edi │ ├── ControlNumbersMismatch.edi │ ├── MultipleInterchangesAndGroups.edi │ ├── NonEdi.edi │ └── WrongGroupsAndTranCount.edi ├── TestUtils.cs ├── XmlReadWriteTests.cs ├── edixml.xsd └── packages.config ├── EdiEngine.sln ├── EdiEngine ├── AckBuilder.cs ├── AckBuilderSettings.cs ├── ActivatorHelper.cs ├── AllowedEntitity.cs ├── DataWriter.cs ├── EdiDataReader.cs ├── EdiDataWriter.cs ├── EdiDataWriterSettings.cs ├── EdiEngine.csproj ├── EdiMapReader.cs ├── EdiParsingException.cs ├── InetermediateFormatReader.cs ├── JsonDataWriter.cs ├── JsonMapReader.cs ├── MapReader.cs ├── Runtime │ ├── DataElementBase.cs │ ├── EdiBaseEntity.cs │ ├── EdiBatch.cs │ ├── EdiCompositeDataElement.cs │ ├── EdiGroup.cs │ ├── EdiHlLoop.cs │ ├── EdiInterchange.cs │ ├── EdiIntermediateEntity.cs │ ├── EdiLoop.cs │ ├── EdiSegment.cs │ ├── EdiSimpleDataElement.cs │ ├── EdiTrans.cs │ ├── GE.cs │ ├── GS.cs │ ├── IEA.cs │ ├── ISA.cs │ ├── SE.cs │ └── ST.cs ├── Validation │ ├── DataElementValidator.cs │ ├── IValidatedEntity.cs │ ├── SegmentValidator.cs │ └── ValidationError.cs ├── Xml │ ├── XmlElementAttribute.cs │ ├── XmlIgnoreAttribute.cs │ └── XmlPropertyAttribute.cs ├── XmlDataWriter.cs ├── XmlMapReader.cs └── packages.config ├── EdiStandards └── X12_004010 │ ├── DataElements │ ├── CompositeDataElements.cs │ └── DataElements.cs │ ├── Maps │ ├── M_100.cs │ ├── M_101.cs │ ├── M_104.cs │ ├── M_105.cs │ ├── M_106.cs │ ├── M_107.cs │ ├── M_108.cs │ ├── M_109.cs │ ├── M_110.cs │ ├── M_112.cs │ ├── M_120.cs │ ├── M_121.cs │ ├── M_124.cs │ ├── M_125.cs │ ├── M_126.cs │ ├── M_127.cs │ ├── M_128.cs │ ├── M_129.cs │ ├── M_130.cs │ ├── M_131.cs │ ├── M_135.cs │ ├── M_138.cs │ ├── M_139.cs │ ├── M_140.cs │ ├── M_141.cs │ ├── M_142.cs │ ├── M_143.cs │ ├── M_144.cs │ ├── M_146.cs │ ├── M_147.cs │ ├── M_148.cs │ ├── M_149.cs │ ├── M_150.cs │ ├── M_151.cs │ ├── M_152.cs │ ├── M_153.cs │ ├── M_154.cs │ ├── M_155.cs │ ├── M_157.cs │ ├── M_159.cs │ ├── M_160.cs │ ├── M_161.cs │ ├── M_163.cs │ ├── M_170.cs │ ├── M_175.cs │ ├── M_176.cs │ ├── M_180.cs │ ├── M_185.cs │ ├── M_186.cs │ ├── M_188.cs │ ├── M_189.cs │ ├── M_190.cs │ ├── M_191.cs │ ├── M_194.cs │ ├── M_195.cs │ ├── M_196.cs │ ├── M_197.cs │ ├── M_198.cs │ ├── M_199.cs │ ├── M_200.cs │ ├── M_201.cs │ ├── M_202.cs │ ├── M_203.cs │ ├── M_204.cs │ ├── M_205.cs │ ├── M_206.cs │ ├── M_210.cs │ ├── M_211.cs │ ├── M_212.cs │ ├── M_213.cs │ ├── M_214.cs │ ├── M_215.cs │ ├── M_216.cs │ ├── M_217.cs │ ├── M_218.cs │ ├── M_219.cs │ ├── M_220.cs │ ├── M_222.cs │ ├── M_223.cs │ ├── M_224.cs │ ├── M_225.cs │ ├── M_242.cs │ ├── M_244.cs │ ├── M_248.cs │ ├── M_249.cs │ ├── M_250.cs │ ├── M_251.cs │ ├── M_252.cs │ ├── M_255.cs │ ├── M_256.cs │ ├── M_260.cs │ ├── M_261.cs │ ├── M_262.cs │ ├── M_263.cs │ ├── M_264.cs │ ├── M_265.cs │ ├── M_266.cs │ ├── M_267.cs │ ├── M_268.cs │ ├── M_270.cs │ ├── M_271.cs │ ├── M_272.cs │ ├── M_273.cs │ ├── M_275.cs │ ├── M_276.cs │ ├── M_277.cs │ ├── M_278.cs │ ├── M_280.cs │ ├── M_285.cs │ ├── M_286.cs │ ├── M_288.cs │ ├── M_290.cs │ ├── M_300.cs │ ├── M_301.cs │ ├── M_303.cs │ ├── M_304.cs │ ├── M_309.cs │ ├── M_310.cs │ ├── M_311.cs │ ├── M_312.cs │ ├── M_313.cs │ ├── M_315.cs │ ├── M_317.cs │ ├── M_319.cs │ ├── M_322.cs │ ├── M_323.cs │ ├── M_324.cs │ ├── M_325.cs │ ├── M_326.cs │ ├── M_350.cs │ ├── M_352.cs │ ├── M_353.cs │ ├── M_354.cs │ ├── M_355.cs │ ├── M_356.cs │ ├── M_357.cs │ ├── M_358.cs │ ├── M_361.cs │ ├── M_362.cs │ ├── M_404.cs │ ├── M_410.cs │ ├── M_414.cs │ ├── M_417.cs │ ├── M_418.cs │ ├── M_419.cs │ ├── M_420.cs │ ├── M_421.cs │ ├── M_422.cs │ ├── M_423.cs │ ├── M_425.cs │ ├── M_426.cs │ ├── M_429.cs │ ├── M_431.cs │ ├── M_432.cs │ ├── M_433.cs │ ├── M_434.cs │ ├── M_435.cs │ ├── M_436.cs │ ├── M_437.cs │ ├── M_440.cs │ ├── M_451.cs │ ├── M_452.cs │ ├── M_453.cs │ ├── M_455.cs │ ├── M_456.cs │ ├── M_460.cs │ ├── M_463.cs │ ├── M_466.cs │ ├── M_468.cs │ ├── M_470.cs │ ├── M_475.cs │ ├── M_485.cs │ ├── M_486.cs │ ├── M_490.cs │ ├── M_492.cs │ ├── M_494.cs │ ├── M_500.cs │ ├── M_501.cs │ ├── M_503.cs │ ├── M_504.cs │ ├── M_511.cs │ ├── M_517.cs │ ├── M_521.cs │ ├── M_527.cs │ ├── M_536.cs │ ├── M_540.cs │ ├── M_561.cs │ ├── M_567.cs │ ├── M_568.cs │ ├── M_601.cs │ ├── M_602.cs │ ├── M_620.cs │ ├── M_625.cs │ ├── M_650.cs │ ├── M_715.cs │ ├── M_805.cs │ ├── M_806.cs │ ├── M_810.cs │ ├── M_811.cs │ ├── M_812.cs │ ├── M_813.cs │ ├── M_814.cs │ ├── M_815.cs │ ├── M_816.cs │ ├── M_818.cs │ ├── M_819.cs │ ├── M_820.cs │ ├── M_821.cs │ ├── M_822.cs │ ├── M_823.cs │ ├── M_824.cs │ ├── M_826.cs │ ├── M_827.cs │ ├── M_828.cs │ ├── M_829.cs │ ├── M_830.cs │ ├── M_831.cs │ ├── M_832.cs │ ├── M_833.cs │ ├── M_834.cs │ ├── M_835.cs │ ├── M_836.cs │ ├── M_837.cs │ ├── M_838.cs │ ├── M_839.cs │ ├── M_840.cs │ ├── M_841.cs │ ├── M_842.cs │ ├── M_843.cs │ ├── M_844.cs │ ├── M_845.cs │ ├── M_846.cs │ ├── M_847.cs │ ├── M_848.cs │ ├── M_849.cs │ ├── M_850.cs │ ├── M_851.cs │ ├── M_852.cs │ ├── M_853.cs │ ├── M_854.cs │ ├── M_855.cs │ ├── M_856.cs │ ├── M_857.cs │ ├── M_858.cs │ ├── M_859.cs │ ├── M_860.cs │ ├── M_861.cs │ ├── M_862.cs │ ├── M_863.cs │ ├── M_864.cs │ ├── M_865.cs │ ├── M_866.cs │ ├── M_867.cs │ ├── M_868.cs │ ├── M_869.cs │ ├── M_870.cs │ ├── M_871.cs │ ├── M_872.cs │ ├── M_875.cs │ ├── M_876.cs │ ├── M_877.cs │ ├── M_878.cs │ ├── M_879.cs │ ├── M_880.cs │ ├── M_881.cs │ ├── M_882.cs │ ├── M_883.cs │ ├── M_884.cs │ ├── M_885.cs │ ├── M_886.cs │ ├── M_887.cs │ ├── M_888.cs │ ├── M_889.cs │ ├── M_891.cs │ ├── M_893.cs │ ├── M_894.cs │ ├── M_895.cs │ ├── M_896.cs │ ├── M_920.cs │ ├── M_924.cs │ ├── M_925.cs │ ├── M_926.cs │ ├── M_928.cs │ ├── M_940.cs │ ├── M_943.cs │ ├── M_944.cs │ ├── M_945.cs │ ├── M_947.cs │ ├── M_980.cs │ ├── M_990.cs │ ├── M_996.cs │ ├── M_997.cs │ └── M_998.cs │ ├── Segments │ └── Segments.cs │ └── X12_004010.csproj ├── LICENSE ├── README.md ├── ReleaseNotes.txt └── _nuget ├── config.nuspec ├── pkg.bat └── pushSymbols.bat /EdiEngine.Common/Definitions/MapBaseDataElement.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | 3 | namespace EdiEngine.Common.Definitions 4 | { 5 | public abstract class MapBaseDataElement 6 | { 7 | public RequirementDesignator ReqDes { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /EdiEngine.Common/Definitions/MapBaseEntity.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | 3 | namespace EdiEngine.Common.Definitions 4 | { 5 | public abstract class MapBaseEntity 6 | { 7 | protected MapBaseEntity() 8 | { 9 | Name = GetType().Name; 10 | ReqDes = RequirementDesignator.Optional; 11 | } 12 | 13 | public string Name { get; } 14 | 15 | public abstract string EdiName { get; } 16 | 17 | public RequirementDesignator ReqDes { get; set; } 18 | 19 | public int MaxOccurs { get; set; } 20 | 21 | public int OccuredTimes { get; set; } 22 | 23 | public override string ToString() 24 | { 25 | return Name; 26 | } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /EdiEngine.Common/Definitions/MapCompositeDataElement.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using EdiEngine.Common.Enums; 3 | 4 | namespace EdiEngine.Common.Definitions 5 | { 6 | public class MapCompositeDataElement : MapBaseDataElement 7 | { 8 | public MapCompositeDataElement() 9 | { 10 | Name = GetType().Name; 11 | ReqDes = RequirementDesignator.Optional; 12 | Content = new List(); 13 | } 14 | 15 | public string Name { get; } 16 | 17 | public List Content { get; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /EdiEngine.Common/Definitions/MapLoop.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace EdiEngine.Common.Definitions 4 | { 5 | public abstract class MapLoop : MapBaseEntity 6 | { 7 | protected MapLoop(MapLoop parentLoop) 8 | { 9 | ParentLoop = parentLoop; 10 | MaxOccurs = 1000; 11 | Content = new List(); 12 | } 13 | 14 | public List Content { get; } 15 | 16 | public MapLoop ParentLoop { get; } 17 | 18 | public int CurrentPos { get; set; } 19 | 20 | public override string EdiName => Name.Remove(0, 2); 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /EdiEngine.Common/Definitions/MapSegment.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | 3 | namespace EdiEngine.Common.Definitions 4 | { 5 | public abstract class MapSegment : MapBaseEntity 6 | { 7 | protected MapSegment() 8 | { 9 | MaxOccurs = 1; 10 | Content = new List(); 11 | SyntaxNotes = new List(); 12 | } 13 | 14 | public override string EdiName => Name; 15 | 16 | public List Content { get; } 17 | 18 | public List SyntaxNotes { get; } 19 | 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /EdiEngine.Common/Definitions/MapSimpleDataElement.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using System.Collections.Generic; 3 | 4 | namespace EdiEngine.Common.Definitions 5 | { 6 | public abstract class MapSimpleDataElement : MapBaseDataElement 7 | { 8 | protected MapSimpleDataElement() 9 | { 10 | ReqDes = RequirementDesignator.Optional; 11 | AllowedValues = new List(); 12 | } 13 | 14 | public DataType DataType { get; set; } 15 | 16 | public int MinLength { get; set; } 17 | 18 | public int MaxLength { get; set; } 19 | 20 | public List AllowedValues { get; } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /EdiEngine.Common/EdiEngine.Common.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netstandard2.0 5 | EdiEngine.Common 6 | EdiEngine.Common 7 | 1.6.0.0 8 | 1.6.0.0 9 | 1.6.0.0 10 | Edi Engine comon library 11 | https://github.com/olmelabs/EdiEngine 12 | https://github.com/olmelabs/EdiEngine 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /EdiEngine.Common/Enums/DataType.cs: -------------------------------------------------------------------------------- 1 | namespace EdiEngine.Common.Enums 2 | { 3 | public enum DataType 4 | { 5 | AN, 6 | DT, 7 | TM, 8 | ID, 9 | N0, 10 | N1, 11 | N2, 12 | N4, 13 | N6, 14 | R, 15 | R2, 16 | R4, 17 | R5, 18 | R6, 19 | R7, 20 | R8, 21 | R9, 22 | B 23 | 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /EdiEngine.Common/Enums/RequirementDesignator.cs: -------------------------------------------------------------------------------- 1 | namespace EdiEngine.Common.Enums 2 | { 3 | public enum RequirementDesignator 4 | { 5 | Mandatory, 6 | Optional 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/ConditionalSyntaxNote.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | 3 | namespace EdiEngine.Common.SyntaxNotes 4 | { 5 | public class ConditionalSyntaxNote : SyntaxNote 6 | { 7 | public ConditionalSyntaxNote(string syntaxNote) : base(syntaxNote) 8 | { 9 | } 10 | 11 | protected override string Description 12 | => " If the first element specified in the condition is present, then all others must be present"; 13 | 14 | public override bool IsValid(string[] content) 15 | { 16 | var res = Elements.Select(idx => GetExtendedList(content)[idx]).ToList(); 17 | 18 | if (string.IsNullOrEmpty(res.FirstOrDefault())) 19 | return true; 20 | 21 | return !res.Any(string.IsNullOrEmpty); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/ExclusionSyntaxNote.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | 3 | namespace EdiEngine.Common.SyntaxNotes 4 | { 5 | public class ExclusionSyntaxNote : SyntaxNote 6 | { 7 | public ExclusionSyntaxNote(string syntaxNote) : base(syntaxNote) 8 | { 9 | } 10 | 11 | protected override string Description => "Not more than one can be present."; 12 | 13 | public override bool IsValid(string[] content) 14 | { 15 | var res = Elements.Select(idx => GetExtendedList(content)[idx]).ToList(); 16 | 17 | return res.Count(x => !string.IsNullOrEmpty(x)) <= 1; 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/ListConditionalSyntaxNote.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | 3 | namespace EdiEngine.Common.SyntaxNotes 4 | { 5 | public class ListConditionalSyntaxNote : SyntaxNote 6 | { 7 | public ListConditionalSyntaxNote(string syntaxNote) : base(syntaxNote) 8 | { 9 | } 10 | 11 | protected override string Description 12 | => "If the first element specified is present, then at least one of the remaining elements must be present."; 13 | 14 | public override bool IsValid(string[] content) 15 | { 16 | var res = Elements.Select(idx => GetExtendedList(content)[idx]).ToList(); 17 | 18 | if (string.IsNullOrEmpty(res.FirstOrDefault())) 19 | return true; 20 | 21 | return res.Skip(1).Any(x => !string.IsNullOrEmpty(x)); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/PairedSyntaxNote.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | 3 | namespace EdiEngine.Common.SyntaxNotes 4 | { 5 | public class PairedSyntaxNote : SyntaxNote 6 | { 7 | public PairedSyntaxNote(string syntaxNote) : base(syntaxNote) 8 | { 9 | } 10 | 11 | protected override string Description 12 | => "If any element specified in the relational condition is present, then all must be present."; 13 | 14 | public override bool IsValid(string[] content) 15 | { 16 | var res = Elements.Select(idx => GetExtendedList(content)[idx]).ToList(); 17 | 18 | return res.Any(string.IsNullOrEmpty) ^ res.Any(x => !string.IsNullOrEmpty(x)); 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/RequiredSyntaxNote.cs: -------------------------------------------------------------------------------- 1 | using System.Linq; 2 | 3 | namespace EdiEngine.Common.SyntaxNotes 4 | { 5 | public class RequiredSyntaxNote : SyntaxNote 6 | { 7 | public RequiredSyntaxNote(string syntaxNote) : base(syntaxNote) 8 | { 9 | } 10 | 11 | protected override string Description => "At least one specified in the relational condition must be present"; 12 | 13 | public override bool IsValid(string[] content) 14 | { 15 | var res = Elements.Select(idx => GetExtendedList(content)[idx]).ToList(); 16 | 17 | return res.Any(x => !string.IsNullOrEmpty(x)); 18 | } 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/SyntaxNote.cs: -------------------------------------------------------------------------------- 1 |  2 | using System.Collections.Generic; 3 | using System.Linq; 4 | 5 | namespace EdiEngine.Common.SyntaxNotes 6 | { 7 | public abstract class SyntaxNote 8 | { 9 | private readonly string _syntaxNote; 10 | protected List Elements; 11 | 12 | protected SyntaxNote(string syntaxNote) 13 | { 14 | _syntaxNote = syntaxNote; 15 | Elements = new List(); 16 | Elements.AddRange(GetElements(syntaxNote)); 17 | } 18 | 19 | protected abstract string Description { get; } 20 | 21 | public override string ToString() 22 | { 23 | return $"{_syntaxNote} - {Description}"; 24 | } 25 | 26 | public abstract bool IsValid(string[] content); 27 | 28 | private IEnumerable GetElements(string s) 29 | { 30 | s = s.Remove(0, 1); 31 | for (var i = 0; i < s.Length; i += 2) 32 | yield return int.Parse(s.Substring(i, 2)) - 1; 33 | } 34 | 35 | /// 36 | /// add empty elements to the end of list so we do not have index ut of range 37 | /// 38 | /// 39 | /// 40 | protected List GetExtendedList(string[] content) 41 | { 42 | int maxPos = Elements.Max(); 43 | if (maxPos < content.Length) 44 | return new List(content); 45 | 46 | List contentCopy = new List(maxPos); 47 | contentCopy.AddRange(content); 48 | contentCopy.AddRange(Enumerable.Repeat("", maxPos - content.Length + 1)); 49 | 50 | return contentCopy; 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /EdiEngine.Common/SyntaxNotes/SyntaxNoteFactory.cs: -------------------------------------------------------------------------------- 1 |  2 | using System; 3 | 4 | namespace EdiEngine.Common.SyntaxNotes 5 | { 6 | /// 7 | /// P Paired 8 | /// If any element specified in the relational condition is present, then all must be present 9 | /// R Required 10 | /// At least one specified in the relational condition must be present 11 | /// E Exclusion 12 | /// Not more than one can be present 13 | /// C Conditional 14 | /// If the first element specified in the condition is present, then all others must be present 15 | /// L List Conditional 16 | /// If the first element specified is present, then at least one of the remaining elements must be present 17 | /// 18 | public enum SyntaxNoteType 19 | { 20 | Conditional, 21 | Exclusion, 22 | ListConditional, 23 | Paired, 24 | Required 25 | } 26 | 27 | public class SyntaxNoteFactory 28 | { 29 | public static SyntaxNote GetSyntaxNote(string syntaxNote) 30 | { 31 | switch (syntaxNote[0]) 32 | { 33 | case 'C': 34 | return new ConditionalSyntaxNote(syntaxNote); 35 | 36 | case 'E': 37 | return new ExclusionSyntaxNote(syntaxNote); 38 | 39 | case 'L': 40 | return new ListConditionalSyntaxNote(syntaxNote); 41 | 42 | case 'P': 43 | return new PairedSyntaxNote(syntaxNote); 44 | 45 | case 'R': 46 | return new RequiredSyntaxNote(syntaxNote); 47 | 48 | default: 49 | throw new NotImplementedException($"Syntax note {syntaxNote} is not implemented"); 50 | } 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /EdiEngine.Tests/Maps/M_001.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Common.Enums; 3 | using EdiEngine.Tests.Segments; 4 | 5 | namespace EdiEngine.Tests.Maps 6 | { 7 | /// 8 | /// This is fake custom map just for unit tests 9 | /// 10 | public class M_001 : MapLoop 11 | { 12 | public M_001() : base(null) 13 | { 14 | Content.AddRange(new MapBaseEntity[] { 15 | new SLN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 16 | }); 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /EdiEngine.Tests/Maps/M_940.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Common.Enums; 3 | using EdiEngine.Tests.Segments; 4 | 5 | namespace EdiEngine.Tests.Maps 6 | { 7 | public class M_940 : MapLoop 8 | { 9 | public M_940() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new W05() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | }); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /EdiEngine.Tests/Segments/Segments.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Common.Enums; 3 | using EdiEngine.Standards.X12_004010.DataElements; 4 | 5 | namespace EdiEngine.Tests.Segments 6 | { 7 | public class ISA : Standards.X12_004010.Segments.ISA 8 | { 9 | } 10 | 11 | public class IEA : Standards.X12_004010.Segments.IEA 12 | { 13 | } 14 | 15 | public class GS : Standards.X12_004010.Segments.GS 16 | { 17 | } 18 | 19 | public class GE : Standards.X12_004010.Segments.GE 20 | { 21 | } 22 | 23 | public class ST : Standards.X12_004010.Segments.ST 24 | { 25 | } 26 | 27 | public class SE : Standards.X12_004010.Segments.SE 28 | { 29 | } 30 | 31 | public class W05 : Standards.X12_004010.Segments.W05 32 | { 33 | } 34 | 35 | public class SLN : Standards.X12_004010.Segments.SLN 36 | { 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/001.Fake.Composite.json: -------------------------------------------------------------------------------- 1 | { 2 | "Type": "M", 3 | "Name": "M_001", 4 | "Content": [ 5 | { 6 | "Type": "S", 7 | "Name": "SLN", 8 | "Content": [ 9 | { "E": "1.1" }, 10 | { "E": "" }, 11 | { "E": "I" }, 12 | { "E": "10000" }, 13 | { 14 | "Type": "C", 15 | "Name": "C001", 16 | "Content": [ 17 | { "E": "PC" }, 18 | { "E": "21.1" }, 19 | { "E": "22.2" }, 20 | { "E": "EA" }, 21 | { "E": "23.3" }, 22 | { "E": "24.4" } 23 | ] 24 | }, 25 | { "E": "1.56" }, 26 | { "E": "TP" }, 27 | { "E": "" }, 28 | { "E": "VC" }, 29 | { "E": "P-875OS" } 30 | ] 31 | } 32 | ] 33 | } 34 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/001.Fake.Composite.xml: -------------------------------------------------------------------------------- 1 |  2 | M_001 3 | 4 | 5 | SLN 6 | 7 | 1.1 8 | 9 | I 10 | 10000 11 | 12 | C001 13 | 14 | PC 15 | 21.1 16 | 22.2 17 | EA 18 | 23.3 19 | 24.4 20 | 21 | 22 | 1.56 23 | TP 24 | 25 | VC 26 | P-875OS 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/850.Composite.SLN.OK.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*PO*4405197800*999999999*20101127*1719*1421*X*004010 3 | ST*850*000000010 4 | BEG*00*SA*08292233294**20101127*610385385 5 | PO1*1*120*EA*9.25*TE*CB*065322-117*PR*RO*VN*AB3542 6 | PID*F****SMALL WIDGET 7 | SLN*1.1**I*10000*PC>11.1>12.2>EA>13.3>14.4*1.56*TP**VC*P-875OS*UI*09999982001 8 | PO1*2*220*EA*13.79*TE*CB*066850-116*PR*RO*VN*RD5322 9 | PID*F****MEDIUM WIDGET 10 | SLN*1.1**I*10000*PC>21.1>22.2>EA>23.3>24.4*1.56*TP**VC*P-875OS*UI*09999982001 11 | CTT*2 12 | AMT*1*13045.94 13 | SE*11*000000010 14 | GE*1*1421 15 | IEA*1*000003438 16 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/850.OK.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*PO*4405197800*999999999*20101127*1719*1421*X*004010 3 | ST*850*000000010 4 | BEG*00*SA*08292233294**20101127*610385385 5 | REF*DP*038 6 | REF*PS*R 7 | ITD*14*3*2**45**46 8 | DTM*002*20101214 9 | PKG*F*68***PALLETIZE SHIPMENT 10 | PKG*F*66***REGULAR 11 | TD5*A*92*P3**SEE XYZ RETAIL ROUTING GUIDE 12 | N1*ST*XYZ RETAIL*9*0003947268292 13 | N3*31875 SOLON RD 14 | N4*SOLON*OH*44139 15 | PO1*1*120*EA*9.25*TE*CB*065322-117*PR*RO*VN*AB3542 16 | PID*F****SMALL WIDGET 17 | PO4*4*4*EA*PLT94**3*LR*15*CT 18 | PO1*2*220*EA*13.79*TE*CB*066850-116*PR*RO*VN*RD5322 19 | PID*F****MEDIUM WIDGET 20 | PO4*2*2*EA 21 | PO1*3*126*EA*10.99*TE*CB*060733-110*PR*RO*VN*XY5266 22 | PID*F****LARGE WIDGET 23 | PO4*6*1*EA*PLT94**3*LR*12*CT 24 | PO1*4*76*EA*4.35*TE*CB*065308-116*PR*RO*VN*VX2332 25 | PID*F****NANO WIDGET 26 | PO4*4*4*EA*PLT94**6*LR*19*CT 27 | PO1*5*72*EA*7.5*TE*CB*065374-118*PR*RO*VN*RV0524 28 | PID*F****BLUE WIDGET 29 | PO4*4*4*EA 30 | PO1*6*696*EA*9.55*TE*CB*067504-118*PR*RO*VN*DX1875 31 | PID*F****ORANGE WIDGET 32 | PO4*6*6*EA*PLT94**3*LR*10*CT 33 | CTT*6 34 | AMT*1*13045.94 35 | SE*33*000000010 36 | GE*1*1421 37 | IEA*1*000003438 38 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/850.SyntaxNotes.ERR.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*PO*4405197800*999999999*20101127*1719*1421*X*004010 3 | ST*850*000000010 4 | BEG*00*SA*08292233294**20101127*610385385 5 | REF*DP*038 6 | REF*PS*R 7 | ITD*14*3*2**45**46 8 | DTM*002*20101214 9 | PKG*F*68***PALLETIZE SHIPMENT 10 | PKG*F*66***REGULAR 11 | TD5*A*92*P3**SEE XYZ RETAIL ROUTING GUIDE 12 | N1*ST*XYZ RETAIL*9*0003947268292 13 | N3*31875 SOLON RD 14 | N4*SOLON*OH*44139 15 | PO1*1*120*EA*9.25*TE*CB**PR*RO*VN*AB3542 16 | PID*F****SMALL WIDGET 17 | PO4*4*4*EA*PLT94**3*LR*15*CT 18 | PO1*2*220*EA*13.79*TE*CB*066850-116*PR*RO*VN*RD5322 19 | PID*F****MEDIUM WIDGET 20 | PO4*2*2*EA 21 | PO1*3*126*EA*10.99*TE*CB*060733-110*PR*RO*VN*XY5266 22 | PID*F****LARGE WIDGET 23 | PO4*6*1*EA*PLT94**3*LR*12*CT 24 | PO1*4*76*EA*4.35*TE*CB*065308-116*PR*RO*VN*VX2332 25 | PID*F****NANO WIDGET 26 | PO4*4*4*EA*PLT94**6*LR*19*CT 27 | PO1*5*72*EA*7.5*TE*CB*065374-118*PR*RO*VN*RV0524 28 | PID*F****BLUE WIDGET 29 | PO4*4*4*EA 30 | PO1*6*696*EA*9.55*TE*CB*067504-118*PR*RO*VN*DX1875 31 | PID*F****ORANGE WIDGET 32 | PO4*6*6*EA*PLT94*X**LR*10*CT 33 | CTT*6 34 | AMT*1*13045.94 35 | SE*33*000000010 36 | GE*1*1421 37 | IEA*1*000003438 38 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/856.Crossdock.OK.edi: -------------------------------------------------------------------------------- 1 | ISA*00* *00* *ZZ*SENDER *ZZ*RECEIVER *091225*1943*U*00401*000000091*0*P*> 2 | GS*SH*SENDER*RECEIVER*20091225*1943*91*X*004010 3 | ST*856*0001 4 | BSN*00*000009*20090921*0801*0001 5 | HL*1**S 6 | TD1*CTN*5*****24*LB*123*CF 7 | TD5**2*OVNT**OVERNITE 8 | TD3*TL**1234567890 9 | REF*BM*000001 10 | REF*CN*0000000008741 11 | REF*SE*0000000008741 12 | DTM*011*20090921 13 | DTM*017*20090925 14 | FOB*PP 15 | N1*SF*SOME COMPANY*92*000009 16 | N3*SOME STREET 17 | N4*CITY*CA*90210 18 | N1*ST*RETAILER*92*0001 19 | HL*2*1*O 20 | PRF*POREF00 21 | TD1*CTN*4 22 | REF*IV*0000021 23 | N1*BY*STORE*92*002 24 | HL*3*2*P 25 | PO4*123*****6*LB 26 | MAN*GM*00000715670002152360 27 | HL*4*3*I 28 | LIN**UP*0000000000642 29 | SN1**12*EA 30 | HL*5*2*P 31 | MAN*GM*00000715670002152377 32 | HL*6*5*I 33 | LIN**EN*0000000000831 34 | SN1**12*EA 35 | HL*7*2*P 36 | PO4******6*LB 37 | MAN*GM*00000715670002152384 38 | HL*8*7*I 39 | LIN**UP*0000000000283 40 | SN1**12*EA 41 | HL*9*2*P 42 | PO4******6*LB 43 | MAN*GM*00000715670002152391 44 | HL*10*9*I 45 | LIN**UP*0000000000203 46 | SN1**12*EA 47 | HL*11*1*O 48 | PRF*POREF01 49 | TD1*CTN*1 50 | REF*IV*0000022 51 | N1*BY*SRTORE*92*003 52 | HL*12*11*P 53 | PO4*123*****6*LB 54 | MAN*GM*00000715670002152111 55 | HL*13*12*I 56 | LIN**UP*0000000000642 57 | SN1**12*EA 58 | CTT*13 59 | SE*57*0001 60 | GE*1*91 61 | IEA*1*000000091 62 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/940.2.OK.edi: -------------------------------------------------------------------------------- 1 | ISA*00* *00* *ZZ*VENDOR *ZZ*WAREHOUSE *090902*0900*U*00401*000009221*0*P*> 2 | GS*OW*VENDOR*WAREHOUSE*20090902*1700*9221*X*004010 3 | ST*940*20066 4 | W05*N*35131*POMAIL 5 | W66*PP*A***UPS GROUND 6 | LX*1 7 | W01*1*EA*000100022220*VC*110220*UP*871209028795 8 | N9*IA*390003 9 | N9*PC*3 10 | N9*PD*323343435 11 | SE*9*20066 12 | GE*1*9221 13 | IEA*1*000009221 -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/940.OK.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*OW*7705551212*3111350000*20000128*0557*3317*T*004010 3 | ST*940*0001 4 | W05*N*538686**001001*538686 5 | N1*ST*ST COMPANY*ZZ*00000001 6 | N3*ADDRESS 7 | N4*CITY*CA*00003 8 | N1*DE*DE COMPANY*9*0000000000001 9 | N3*ADDRESS 10 | N4*CITY*MN*000001 11 | N1*WH*WHNAME*9*0000000000140 12 | N4*CITY*CA*91761 13 | N9*BR*R1121 14 | G62*10*20000204 15 | G62*02*20000207 16 | NTE*WHI*SHIP ON CHEP PALLETS 17 | W66*PP*M***MTEN 18 | LX*1 19 | W01*12*CA*000100000010*VN*000100*UC*DEC0199******19991205 20 | G69*11.500 STRUD BLUBRY 21 | N9*PC*DEC0199 22 | LX*2 23 | W01*32*CA*000000000220*VN*000200*UC*DEC0299******19991207 24 | G69*11.500 STRUD CINN 25 | N9*PC*DEC0299 26 | LX*3 27 | W01*12*CA*000000000330*VN*000300*UC*JAN0100******20000107 28 | G69*11.500 STRUDEL RASPBRY 29 | N9*PC*JAN0100 30 | W76*56*500*LB*24*CF 31 | SE*29*0001 32 | GE*1*3317 33 | IEA*1*000003438 -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/940.W05.Only.edi: -------------------------------------------------------------------------------- 1 | ISA*00* *00* *ZZ*VENDOR *ZZ*WAREHOUSE *090902*0900*U*00401*000009221*0*P*> 2 | GS*OW*VENDOR*WAREHOUSE*20090902*1700*9221*X*004010 3 | ST*940*20066 4 | W05*N*35131*POMAIL 5 | SE*3*20066 6 | GE*1*9221 7 | IEA*1*000009221 -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/940_Failed_SE01.edi: -------------------------------------------------------------------------------- 1 | ISA*00* *00* *ZZ*VENDOR *ZZ*WAREHOUSE *090902*0900*U*00401*000009221*0*P*> 2 | GS*OW*VENDOR*WAREHOUSE*20090902*1700*9221*X*004010 3 | ST*940*20066 4 | W05*N*35131*POMAIL 5 | W66*PP*A***UPS GROUND***G033*43.00*UPSN 6 | LX*1 7 | W01**1*EA*VC*110220*UP*871209028795 8 | N9*IA*390003 9 | N9*PC*3 10 | N9*PD*323343435 11 | SE*12*20066 12 | GE*1*9221 13 | IEA*1*000009221 -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/AckTest.edi: -------------------------------------------------------------------------------- 1 | ISA*00* *00* *ZZ*VENDOR *ZZ*WAREHOUSE *090902*0900*U*00401*000009221*0*P*> 2 | GS*OW*VENDOR*WAREHOUSE*20090902*1700*9221*X*004010 3 | ST*940*20066 4 | W05*N*35131*POMAIL 5 | W66*PP*M***MTEN 6 | LX*1 7 | W01*1*EA*000100022220*VC*110220*UP*871209028795 8 | N9*IA*390003 9 | N9*PC*3 10 | N9*PD*323343435 11 | SE*9*20066 12 | ST*940*20067 13 | W05*N*35131*POMAIL 14 | W66*PP*M***MTEN 15 | LX*1 16 | W01*1*EA*000100022220*VC*110220*UP*871209028795 17 | N9*IA*390003 18 | N9**3 19 | N9*PD*323343435 20 | SE*9*20067 21 | GE*2*9221 22 | GS*OW*VENDOR*WAREHOUSE*20090902*1700*9222*X*004010 23 | ST*940*20068 24 | W05*N*35131*POMAIL 25 | W66*PP*M***MTEN*43.00 26 | LX*1 27 | W01*1*EA*000100022220*VC*110220*UP*871209028795 28 | N9*IA*390003 29 | N9*PC*3 30 | N9*PD*323343435 31 | SE*9*20068 32 | GE*1*9222 33 | IEA*2*000009221 -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/ControlNumbersMismatch.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*OW*7705551212*3111350000*20000128*0557*3314*T*004010 3 | ST*940*0001 4 | W05*N*538686**001001*538686 5 | LX*1 6 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 7 | SE*5*0002 8 | GE*1*3315 9 | IEA*1*000003439 10 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/MultipleInterchangesAndGroups.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*OW*7705551212*3111350000*20000128*0557*3313*T*004010 3 | ST*940*0001 4 | W05*N*538686**001001*538686 5 | LX*1 6 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 7 | SE*5*0001 8 | ST*940*0002 9 | W05*N*538686**001001*538686 10 | LX*1 11 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 12 | SE*5*0002 13 | GE*2*3313 14 | GS*OW*7705551212*3111350000*20000128*0557*3314*T*004010 15 | ST*940*0001 16 | W05*N*538686**001001*538686 17 | LX*1 18 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 19 | SE*5*0001 20 | GE*1*3314 21 | IEA*2*3438 22 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003439*0*P*> 23 | GS*OW*7705551212*3111350000*20000128*0557*3315*T*004010 24 | ST*940*0001 25 | W05*N*538686**001001*538686 26 | LX*1 27 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 28 | SE*5*0001 29 | ST*940*0002 30 | W05*N*538686**001001*538686 31 | LX*1 32 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 33 | SE*5*0002 34 | GE*2*3315 35 | GS*OW*7705551212*3111350000*20000128*0557*3316*T*004010 36 | ST*940*0001 37 | W05*N*538686**001001*538686 38 | LX*1 39 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 40 | SE*5*0001 41 | GE*1*3316 42 | IEA*2*3439 -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/NonEdi.edi: -------------------------------------------------------------------------------- 1 | Tk9OIEVESSBGSUxFISAasadsdfs -------------------------------------------------------------------------------- /EdiEngine.Tests/TestData/WrongGroupsAndTranCount.edi: -------------------------------------------------------------------------------- 1 | ISA*01*0000000000*01*0000000000*ZZ*ABCDEFGHIJKLMNO*ZZ*123456789012345*101127*1719*U*00400*000003438*0*P*> 2 | GS*OW*7705551212*3111350000*20000128*0557*3314*T*004010 3 | ST*940*0001 4 | W05*N*538686**001001*538686 5 | LX*1 6 | W01*12*CA*000100011110*VN*000100*UC*DEC0199******19991205 7 | SE*5*0001 8 | GE*2*3314 9 | IEA*2*3438 10 | -------------------------------------------------------------------------------- /EdiEngine.Tests/TestUtils.cs: -------------------------------------------------------------------------------- 1 | using System.IO; 2 | using System.Linq; 3 | using EdiEngine.Runtime; 4 | using SegmentDefinitions = EdiEngine.Standards.X12_004010.Segments; 5 | 6 | namespace EdiEngine.Tests 7 | { 8 | public class TestUtils 9 | { 10 | public static string ReadResourceStream(string resourceName) 11 | { 12 | using (var s = typeof(TestUtils).Assembly.GetManifestResourceStream(resourceName)) 13 | { 14 | if (s == null) 15 | throw new InvalidDataException("stream is null"); 16 | 17 | using (StreamReader sr = new StreamReader(s)) 18 | { 19 | return sr.ReadToEnd(); 20 | } 21 | } 22 | } 23 | 24 | public static string WriteEdiEnvelope(EdiTrans t, string functionalCode) 25 | { 26 | //create batch 27 | EdiBatch b = new EdiBatch(); 28 | b.Interchanges.Add(new EdiInterchange()); 29 | b.Interchanges.First().Groups.Add(new EdiGroup(functionalCode)); 30 | b.Interchanges.First().Groups.First().Transactions.Add(t); 31 | 32 | //Add all service segments 33 | EdiDataWriterSettings settings = new EdiDataWriterSettings( 34 | new SegmentDefinitions.ISA(), new SegmentDefinitions.IEA(), 35 | new SegmentDefinitions.GS(), new SegmentDefinitions.GE(), 36 | new SegmentDefinitions.ST(), new SegmentDefinitions.SE(), 37 | "ZZ", "SENDER", "ZZ", "RECEIVER", "GSSENDER", "GSRECEIVER", 38 | "00401", "004010", "T", 100, 200, "\r\n", "*"); 39 | 40 | EdiDataWriter w = new EdiDataWriter(settings); 41 | return w.WriteToString(b); 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /EdiEngine.Tests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /EdiEngine/AckBuilderSettings.cs: -------------------------------------------------------------------------------- 1 | namespace EdiEngine 2 | { 3 | public enum AckValidationErrorBehavour 4 | { 5 | AcceptAll, 6 | AcceptButNoteErrors, 7 | RejectValidationErrors, 8 | } 9 | 10 | public class AckBuilderSettings 11 | { 12 | public AckBuilderSettings( 13 | AckValidationErrorBehavour validationErrorBehavour, 14 | bool alwaysGenerateAk2Loop, 15 | int isaFirstControlNumber, 16 | int gsFirstControlNumber 17 | ) 18 | { 19 | AckValidationErrorBehavour = validationErrorBehavour; 20 | AlwaysGenerateAk2Loop = alwaysGenerateAk2Loop; 21 | IsaFirstControlNumber = isaFirstControlNumber; 22 | GsFirstControlNumber = gsFirstControlNumber; 23 | } 24 | 25 | public AckValidationErrorBehavour AckValidationErrorBehavour { get; } 26 | 27 | public bool AlwaysGenerateAk2Loop { get; } 28 | 29 | public int IsaFirstControlNumber { get; } 30 | public int GsFirstControlNumber { get; } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /EdiEngine/ActivatorHelper.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Reflection; 3 | 4 | namespace EdiEngine 5 | { 6 | public static class ActivatorHelper 7 | { 8 | public static object Instantiate(string asmName, string typeName) 9 | { 10 | Type t = Type.GetType($"{typeName}, {asmName}", 11 | Assembly.Load, 12 | (assm, name, ignore) => assm.GetType(name, false, ignore), 13 | false); 14 | 15 | if (t == null) 16 | { 17 | throw new TypeLoadException($"Can not resolve type asm: {asmName}, type: {typeName}"); 18 | } 19 | return Activator.CreateInstance(t); 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /EdiEngine/AllowedEntitity.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | 3 | 4 | namespace EdiEngine 5 | { 6 | public class AllowedEntitity 7 | { 8 | public AllowedEntitity(MapBaseEntity entity, MapLoop loopContext) 9 | { 10 | Entity = entity; 11 | LoopContext = loopContext; 12 | } 13 | 14 | public MapBaseEntity Entity { get; } 15 | public MapLoop LoopContext { get; } 16 | 17 | public override string ToString() 18 | { 19 | return $"{Entity.Name} - {LoopContext.Name}"; 20 | } 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /EdiEngine/DataWriter.cs: -------------------------------------------------------------------------------- 1 |  2 | using System.IO; 3 | using EdiEngine.Runtime; 4 | 5 | namespace EdiEngine 6 | { 7 | public abstract class DataWriter 8 | { 9 | public abstract Stream WriteToStream(EdiBatch batch); 10 | 11 | public abstract string WriteToString(EdiBatch batch); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /EdiEngine/EdiEngine.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netstandard2.0 5 | EdiEngine 6 | EdiEngine 7 | Edi Engine main library 8 | https://github.com/olmelabs/EdiEngine 9 | https://github.com/olmelabs/EdiEngine 10 | 1.6.0.0 11 | 1.6.0.0 12 | 1.6.0.0 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /EdiEngine/EdiParsingException.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace EdiEngine 4 | { 5 | public class EdiParsingException : Exception 6 | { 7 | public EdiParsingException(string message) : base(message) { } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /EdiEngine/JsonDataWriter.cs: -------------------------------------------------------------------------------- 1 | using System.IO; 2 | using EdiEngine.Runtime; 3 | using Newtonsoft.Json; 4 | 5 | namespace EdiEngine 6 | { 7 | public class JsonDataWriter : DataWriter 8 | { 9 | public override Stream WriteToStream(EdiBatch batch) 10 | { 11 | MemoryStream s = new MemoryStream(); 12 | StreamWriter w = new StreamWriter(s); 13 | var serializer = new JsonSerializer(); 14 | serializer.Serialize(w, batch); 15 | w.Flush(); 16 | 17 | s.Position = 0; 18 | return s; 19 | } 20 | 21 | public override string WriteToString(EdiBatch batch) 22 | { 23 | return JsonConvert.SerializeObject(batch); 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /EdiEngine/JsonMapReader.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Runtime; 3 | using Newtonsoft.Json; 4 | using System.IO; 5 | using System.Reflection; 6 | 7 | namespace EdiEngine 8 | { 9 | public class JsonMapReader : InetermediateFormatReader 10 | { 11 | public JsonMapReader(MapLoop map) : base(map) 12 | { 13 | } 14 | 15 | protected override EdiIntermediateEntity ReadIntermediateTree(string rawData) 16 | { 17 | JsonTextReader reader = new JsonTextReader(new StringReader(rawData)); 18 | 19 | EdiIntermediateEntity context = new EdiIntermediateEntity(null); 20 | PropertyInfo prop = null; 21 | 22 | while (reader.Read()) 23 | { 24 | string val; 25 | switch (reader.TokenType) 26 | { 27 | case JsonToken.StartObject: 28 | var ent = new EdiIntermediateEntity(context); 29 | context?.Children.Add(ent); 30 | context = ent; 31 | break; 32 | 33 | case JsonToken.PropertyName: 34 | val = reader.Value.ToString(); 35 | prop = typeof(EdiIntermediateEntity).GetProperty(val); 36 | break; 37 | 38 | case JsonToken.String: 39 | val = reader.Value.ToString(); 40 | prop?.SetValue(context, val); 41 | break; 42 | 43 | case JsonToken.EndObject: 44 | context = context?.Parent; 45 | break; 46 | } 47 | } 48 | return context?.Children[0]; 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/DataElementBase.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Xml; 3 | using Newtonsoft.Json; 4 | 5 | namespace EdiEngine.Runtime 6 | { 7 | public abstract class DataElementBase 8 | { 9 | protected DataElementBase(MapBaseDataElement definition) 10 | { 11 | Definition = definition; 12 | } 13 | 14 | [JsonIgnore] 15 | [XmlIgnore] 16 | public MapBaseDataElement Definition { get; } 17 | 18 | public abstract string Val { get;} 19 | 20 | public override string ToString() 21 | { 22 | return Val ?? string.Empty; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiBaseEntity.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Xml; 3 | using Newtonsoft.Json; 4 | 5 | namespace EdiEngine.Runtime 6 | { 7 | public abstract class EdiBaseEntity 8 | { 9 | protected EdiBaseEntity() 10 | { 11 | 12 | } 13 | 14 | protected EdiBaseEntity(MapBaseEntity definition) 15 | { 16 | if (definition != null) 17 | { 18 | Name = definition.Name; 19 | Definition = definition; 20 | } 21 | } 22 | 23 | [JsonIgnore] 24 | [XmlIgnore] 25 | public MapBaseEntity Definition { get; set; } 26 | 27 | [JsonProperty(Order = 1)] 28 | [XmlProperty(Order = 1)] 29 | public string Name { get; set; } 30 | 31 | [JsonProperty(Order = 0)] 32 | [XmlProperty(Order = 0)] 33 | public abstract string Type { get; } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiBatch.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace EdiEngine.Runtime 5 | { 6 | public class EdiBatch 7 | { 8 | public EdiBatch() 9 | { 10 | Date = DateTime.Now; 11 | Interchanges = new List(); 12 | } 13 | 14 | public DateTime Date { get; set; } 15 | 16 | public List Interchanges { get; set; } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiCompositeDataElement.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Linq; 3 | using EdiEngine.Common.Definitions; 4 | using EdiEngine.Xml; 5 | using Newtonsoft.Json; 6 | 7 | namespace EdiEngine.Runtime 8 | { 9 | [XmlElement(ElementName = "C")] 10 | public class EdiCompositeDataElement : DataElementBase 11 | { 12 | private readonly string _compositeSeparator; 13 | public EdiCompositeDataElement(MapBaseDataElement definition, string compositeSeparator = null) : base(definition) 14 | { 15 | Name = definition.GetType().Name; 16 | Content = new List(); 17 | _compositeSeparator = compositeSeparator; 18 | } 19 | 20 | [JsonIgnore] 21 | [XmlIgnore] 22 | public new MapCompositeDataElement Definition => (MapCompositeDataElement)base.Definition; 23 | 24 | [JsonProperty(Order = 0)] 25 | [XmlIgnore] 26 | public string Type => "C"; 27 | 28 | [JsonProperty(Order = 1)] 29 | [XmlProperty(Order = 1)] 30 | public string Name { get; } 31 | 32 | [JsonProperty(Order = 10)] 33 | [XmlProperty(Order = 10)] 34 | public List Content { get; } 35 | 36 | [JsonIgnore] 37 | [XmlIgnore] 38 | public override string Val 39 | { 40 | get 41 | { 42 | if (Content.Count == 0) 43 | return string.Empty; 44 | 45 | var res = Content.Aggregate(string.Empty, 46 | (curr, next) => curr + (_compositeSeparator ?? EdiInterchange.DefaultCompositeSeparator) + next.Val); 47 | return res.Remove(0, 1); 48 | } 49 | } 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiGroup.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using System.Collections.Generic; 3 | using EdiEngine.Validation; 4 | using EdiEngine.Xml; 5 | 6 | namespace EdiEngine.Runtime 7 | { 8 | public class EdiGroup : IValidatedEntity 9 | { 10 | public EdiGroup(string functionalCode) 11 | { 12 | FunctionalCode = functionalCode; 13 | Transactions = new List(); 14 | ValidationErrors = new List(); 15 | } 16 | 17 | /// 18 | /// GS01 19 | /// 20 | [XmlProperty(Order = 1)] 21 | public string FunctionalCode { get; } 22 | 23 | [XmlProperty(Order = 2)] 24 | public EdiSegment GS { get; set; } 25 | 26 | [XmlProperty(Order = 3)] 27 | public EdiSegment GE { get; set; } 28 | 29 | [XmlProperty(Order = 4)] 30 | public List Transactions { get; set; } 31 | 32 | [JsonProperty(Order = 100)] 33 | [XmlProperty(Order = 100)] 34 | public virtual List ValidationErrors { get; } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiHlLoop.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Xml; 3 | using Newtonsoft.Json; 4 | 5 | namespace EdiEngine.Runtime 6 | { 7 | [XmlElement(ElementName = "EdiLoop")] 8 | public class EdiHlLoop : EdiLoop 9 | { 10 | public EdiHlLoop(MapBaseEntity definition, 11 | EdiLoop parent, 12 | int HL01, 13 | int? HL02 14 | ) : base(definition, parent) 15 | { 16 | HL01_HierarchicalIdNumber = HL01; 17 | HL02_HierarchicalParentIdNumber = HL02; 18 | } 19 | 20 | [JsonProperty(Order = 5)] 21 | [XmlProperty(Order = 5)] 22 | public int HL01_HierarchicalIdNumber { get; } 23 | 24 | [JsonProperty(Order = 6)] 25 | [XmlProperty(Order = 6)] 26 | public int? HL02_HierarchicalParentIdNumber { get; } 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiInterchange.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using System.Collections.Generic; 3 | using EdiEngine.Validation; 4 | using EdiEngine.Xml; 5 | 6 | namespace EdiEngine.Runtime 7 | { 8 | public class EdiInterchange : IValidatedEntity 9 | { 10 | public const string DefaultCompositeSeparator = ">"; 11 | 12 | public EdiInterchange() 13 | { 14 | Groups = new List(); 15 | ValidationErrors = new List(); 16 | } 17 | 18 | [XmlProperty(Order = 1)] 19 | public string SegmentSeparator { get; set; } 20 | 21 | [XmlProperty(Order = 2)] 22 | public string ElementSeparator { get; set; } 23 | 24 | [XmlProperty(Order = 3)] 25 | public EdiSegment ISA{ get; set; } 26 | 27 | [XmlProperty(Order = 4)] 28 | public EdiSegment IEA { get; set; } 29 | 30 | [XmlProperty(Order = 5)] 31 | public List Groups { get; set; } 32 | 33 | [JsonProperty(Order = 100)] 34 | [XmlProperty(Order = 100)] 35 | public virtual List ValidationErrors { get; } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiIntermediateEntity.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.IO; 3 | using System.Linq; 4 | 5 | namespace EdiEngine.Runtime 6 | { 7 | public class EdiIntermediateEntity 8 | { 9 | public EdiIntermediateEntity(EdiIntermediateEntity parent) 10 | { 11 | Parent = parent; 12 | Children = new List(); 13 | } 14 | 15 | public string Type { get; set; } 16 | public string Name { get; set; } 17 | public string E { get; set; } 18 | 19 | public EdiIntermediateEntity Parent { get; private set; } 20 | public List Children { get; } 21 | 22 | public TokenContextType EntityType 23 | { 24 | get 25 | { 26 | switch (Type) 27 | { 28 | case "L": 29 | return TokenContextType.Loop; 30 | 31 | case "S": 32 | return TokenContextType.Segment; 33 | 34 | case "C": 35 | return TokenContextType.CompositeDataElement; 36 | 37 | case null: 38 | return TokenContextType.SimpleDataElement; 39 | 40 | default: 41 | throw new InvalidDataException($"Enexpected Type found in Json {Type}"); 42 | } 43 | } 44 | } 45 | 46 | public override string ToString() 47 | { 48 | switch (EntityType) 49 | { 50 | case TokenContextType.SimpleDataElement: 51 | return E; 52 | 53 | case TokenContextType.CompositeDataElement: 54 | return string.Join(EdiInterchange.DefaultCompositeSeparator, Children.Select(c => c.E)); 55 | 56 | default: 57 | return base.ToString(); 58 | 59 | } 60 | } 61 | } 62 | 63 | public enum TokenContextType 64 | { 65 | Loop, 66 | Segment, 67 | CompositeDataElement, 68 | SimpleDataElement, 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiLoop.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using Newtonsoft.Json; 3 | using System.Collections.Generic; 4 | using EdiEngine.Xml; 5 | 6 | namespace EdiEngine.Runtime 7 | { 8 | public class EdiLoop : EdiBaseEntity 9 | { 10 | public EdiLoop() 11 | { 12 | Content = new List(); 13 | } 14 | 15 | public EdiLoop(MapBaseEntity definition, EdiLoop parent) : base(definition) 16 | { 17 | Content = new List(); 18 | Parent = parent; 19 | } 20 | 21 | [JsonProperty(Order = 0)] 22 | [XmlIgnore] 23 | public override string Type => "L"; 24 | 25 | [JsonIgnore] 26 | [XmlIgnore] 27 | public EdiLoop Parent { get; } 28 | 29 | [JsonProperty(Order = 10)] 30 | [XmlProperty(Order = 10)] 31 | public List Content { get; } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiSegment.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using Newtonsoft.Json; 3 | using System.Collections.Generic; 4 | using System.Linq; 5 | using EdiEngine.Xml; 6 | 7 | namespace EdiEngine.Runtime 8 | { 9 | public class EdiSegment : EdiBaseEntity 10 | { 11 | public EdiSegment(MapBaseEntity definition) : base(definition) 12 | { 13 | Content = new List(); 14 | } 15 | 16 | [JsonProperty(Order = 0)] 17 | [XmlIgnore] 18 | public override string Type => "S"; 19 | 20 | [JsonProperty(Order = 10)] 21 | [XmlProperty(Order = 10)] 22 | public List Content { get; } 23 | 24 | public override string ToString() 25 | { 26 | var res = Content.Aggregate(string.Empty, (curr, next) => curr + "*" + next.ToString()); 27 | return $"{Name}*{res.Remove(0, 1)}"; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiSimpleDataElement.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using EdiEngine.Xml; 3 | using Newtonsoft.Json; 4 | 5 | namespace EdiEngine.Runtime 6 | { 7 | [XmlElement(IgnoreElementRoot = true)] 8 | public class EdiSimpleDataElement : DataElementBase 9 | { 10 | public EdiSimpleDataElement(MapBaseDataElement definition, string val) : base(definition) 11 | { 12 | if (definition != null) 13 | { 14 | Type = definition.GetType().Name; 15 | } 16 | Val = val; 17 | } 18 | [JsonIgnore] 19 | [XmlIgnore] 20 | public new MapSimpleDataElement Definition => (MapSimpleDataElement)base.Definition; 21 | 22 | [JsonIgnore] 23 | [XmlIgnore] 24 | public string Type { get; } 25 | 26 | [JsonProperty(Order = 1, PropertyName = "E")] 27 | [XmlProperty(Order = 1, PropertyName = "E")] 28 | public override string Val { get; } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/EdiTrans.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using Newtonsoft.Json; 3 | using System.Collections.Generic; 4 | using EdiEngine.Validation; 5 | using EdiEngine.Xml; 6 | 7 | namespace EdiEngine.Runtime 8 | { 9 | public class EdiTrans : EdiLoop, IValidatedEntity 10 | { 11 | public EdiTrans() 12 | { 13 | ValidationErrors = new List(); 14 | } 15 | 16 | public EdiTrans(MapBaseEntity definition) : base(definition, null) 17 | { 18 | ValidationErrors = new List(); 19 | } 20 | 21 | [JsonProperty(Order = 0)] 22 | [XmlIgnore] 23 | public override string Type => "M"; 24 | 25 | [XmlProperty(Order = 2)] 26 | public EdiSegment ST { get; set; } 27 | 28 | [XmlProperty(Order = 3)] 29 | public EdiSegment SE { get; set; } 30 | 31 | [JsonProperty(Order = 100)] 32 | [XmlProperty(Order = 100)] 33 | public virtual List ValidationErrors { get; } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/GE.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | 3 | namespace EdiEngine.Runtime 4 | { 5 | public class GE: EdiSegment 6 | { 7 | public GE(string[] elements) : base(null) 8 | { 9 | foreach (string el in elements) 10 | { 11 | Content.Add(new EdiSimpleDataElement(null, el)); 12 | } 13 | } 14 | 15 | public GE(MapSegment definition, 16 | int GE01_IncludedTransCount, 17 | int GE02_ControlNumber) : base(definition) 18 | { 19 | Content.AddRange(new[] { 20 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[0], GE01_IncludedTransCount.ToString()), 21 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[1], GE02_ControlNumber.ToString()) 22 | }); 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/GS.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using System; 3 | 4 | namespace EdiEngine.Runtime 5 | { 6 | public class GS : EdiSegment 7 | { 8 | public GS(string[] elements) : base(null) 9 | { 10 | foreach (string el in elements) 11 | { 12 | Content.Add(new EdiSimpleDataElement(null, el)); 13 | } 14 | } 15 | 16 | public GS(MapSegment definition, 17 | string GS01_GroupName, 18 | string GS02_SenderId, 19 | string GS03_ReceiverId, 20 | int GS06_ControlNumber, 21 | string GS08_VersionlNumber 22 | ) : base(definition) 23 | { 24 | Content.AddRange(new[] { 25 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[0], GS01_GroupName), 26 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[1], GS02_SenderId), 27 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[2], GS03_ReceiverId), 28 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[3], DateTime.Now.ToString("yyyyMMdd")), 29 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[4], DateTime.Now.ToString("hhmm")), 30 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[5], GS06_ControlNumber.ToString()), 31 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[6], "X"), 32 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[7], GS08_VersionlNumber) 33 | }); 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/IEA.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | 3 | namespace EdiEngine.Runtime 4 | { 5 | public class IEA : EdiSegment 6 | { 7 | public IEA(string[] elements) : base(null) 8 | { 9 | foreach (string el in elements) 10 | { 11 | Content.Add(new EdiSimpleDataElement(null, el)); 12 | } 13 | } 14 | 15 | public IEA(MapSegment definition, 16 | int IEA01_IncludedGroupsCount, 17 | int IEA02_ControlNumber) : base(definition) 18 | { 19 | Content.AddRange(new[] { 20 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[0], IEA01_IncludedGroupsCount.ToString()), 21 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[1], IEA02_ControlNumber.ToString().PadLeft(9, '0')) 22 | }); 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/ISA.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | using System; 3 | 4 | namespace EdiEngine.Runtime 5 | { 6 | public class ISA : EdiSegment 7 | { 8 | public ISA(string[] elements) : base(null) 9 | { 10 | foreach (string el in elements) 11 | { 12 | Content.Add(new EdiSimpleDataElement(null, el)); 13 | } 14 | } 15 | 16 | public ISA(MapSegment definition, 17 | string ISA05_SenderQual, 18 | string ISA06_SenderId, 19 | string ISA07_ReceiverQual, 20 | string ISA08_ReceiverId, 21 | string ISA12_VersionlNumber, 22 | int ISA13_ControlNumber, 23 | string ISA15_UsageIndicator 24 | ) : base(definition) 25 | { 26 | Content.AddRange(new[] { 27 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[0], "00"), 28 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[1], string.Empty.PadRight(10, ' ')), 29 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[2], "00"), 30 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[3], string.Empty.PadRight(10, ' ')), 31 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[4], ISA05_SenderQual), 32 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[5], ISA06_SenderId.PadRight(15)), 33 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[6], ISA07_ReceiverQual), 34 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[7], ISA08_ReceiverId.PadRight(15)), 35 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[8], DateTime.Now.ToString("yyMMdd")), 36 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[9], DateTime.Now.ToString("hhmm")), 37 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[10], "U"), 38 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[11], ISA12_VersionlNumber), 39 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[12], ISA13_ControlNumber.ToString().PadLeft(9, '0')), 40 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[12], "0"), 41 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[14], ISA15_UsageIndicator), 42 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[15], EdiInterchange.DefaultCompositeSeparator) 43 | }); 44 | } 45 | } 46 | } 47 | 48 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/SE.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | 3 | namespace EdiEngine.Runtime 4 | { 5 | public class SE : EdiSegment 6 | { 7 | public SE(string[] elements) : base(null) 8 | { 9 | foreach (string el in elements) 10 | { 11 | Content.Add(new EdiSimpleDataElement(null, el)); 12 | } 13 | } 14 | 15 | public SE(MapSegment definition, 16 | int SE01_IncludedSegCount, 17 | int SE02_ControlNumber 18 | ) : base(definition) 19 | { 20 | string tcn = SE02_ControlNumber.ToString(); 21 | if (tcn.Length < 4) 22 | { 23 | tcn = tcn.PadLeft(4, '0'); 24 | } 25 | 26 | Content.AddRange(new[] { 27 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[0], SE01_IncludedSegCount.ToString()), 28 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[1], tcn), 29 | }); 30 | } 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /EdiEngine/Runtime/ST.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Definitions; 2 | namespace EdiEngine.Runtime 3 | { 4 | public class ST : EdiSegment 5 | { 6 | public ST(string[] elements) : base(null) 7 | { 8 | foreach (string el in elements) 9 | { 10 | Content.Add(new EdiSimpleDataElement(null, el)); 11 | } 12 | } 13 | 14 | public ST(MapSegment definition, 15 | string ST01_TransactionId, 16 | int ST02_ControlNumber 17 | ) : base(definition) 18 | { 19 | string tcn = ST02_ControlNumber.ToString(); 20 | if (tcn.Length < 4) 21 | { 22 | tcn = tcn.PadLeft(4, '0'); 23 | } 24 | 25 | Content.AddRange(new[] { 26 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[0], ST01_TransactionId), 27 | new EdiSimpleDataElement((MapSimpleDataElement)definition.Content[1], tcn), 28 | }); 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /EdiEngine/Validation/IValidatedEntity.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using EdiEngine.Runtime; 3 | 4 | namespace EdiEngine.Validation 5 | { 6 | public interface IValidatedEntity 7 | { 8 | List ValidationErrors { get; } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /EdiEngine/Validation/ValidationError.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | 3 | namespace EdiEngine.Validation 4 | { 5 | public class ValidationError 6 | { 7 | [JsonProperty(Order = 1)] 8 | public int? SegmentPos { get; set; } 9 | 10 | [JsonProperty(Order = 2)] 11 | public string SegmentName { get; set; } 12 | 13 | [JsonProperty(Order = 3)] 14 | public int? ElementPos { get; set; } 15 | 16 | [JsonProperty(Order = 4)] 17 | public string Message { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /EdiEngine/Xml/XmlElementAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace EdiEngine.Xml 4 | { 5 | [AttributeUsage(AttributeTargets.Class)] 6 | public class XmlElementAttribute : Attribute 7 | { 8 | public bool IgnoreElementRoot { get; set; } 9 | public string ElementName { get; set; } 10 | } 11 | } -------------------------------------------------------------------------------- /EdiEngine/Xml/XmlIgnoreAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace EdiEngine.Xml 4 | { 5 | [AttributeUsage(AttributeTargets.Property)] 6 | public class XmlIgnoreAttribute : Attribute 7 | { 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /EdiEngine/Xml/XmlPropertyAttribute.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace EdiEngine.Xml 4 | { 5 | [AttributeUsage(AttributeTargets.Property)] 6 | public class XmlPropertyAttribute : Attribute 7 | { 8 | public int Order { get; set; } 9 | public string PropertyName { get; set; } 10 | } 11 | } -------------------------------------------------------------------------------- /EdiEngine/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_101.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_101 : MapLoop 8 | { 9 | public M_101() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_DTM(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_DTM : MapLoop 19 | { 20 | public L_DTM(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 25 | new L_LX(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 26 | }); 27 | } 28 | } 29 | 30 | //1100 31 | public class L_LX : MapLoop 32 | { 33 | public L_LX(MapLoop parentLoop) : base(parentLoop) 34 | { 35 | Content.AddRange(new MapBaseEntity[] { 36 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 37 | new IN2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 38 | new NX2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 39 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 40 | new SPA() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 41 | new COM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 42 | }); 43 | } 44 | } 45 | 46 | } 47 | } 48 | 49 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_108.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_108 : MapLoop 8 | { 9 | public M_108() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new BLR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 16 | new L_CA1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99999 }, 17 | }); 18 | } 19 | 20 | //0100 21 | public class L_N1 : MapLoop 22 | { 23 | public L_N1(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 29 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 31 | }); 32 | } 33 | } 34 | 35 | //0200 36 | public class L_CA1 : MapLoop 37 | { 38 | public L_CA1(MapLoop parentLoop) : base(parentLoop) 39 | { 40 | Content.AddRange(new MapBaseEntity[] { 41 | new CA1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 42 | new LC1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 43 | }); 44 | } 45 | } 46 | 47 | } 48 | } 49 | 50 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_109.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_109 : MapLoop 8 | { 9 | public M_109() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new B4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 30 }, 14 | new Q2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new L_R4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_R4 : MapLoop 22 | { 23 | public L_R4(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new R4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 28 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 29 | new L_N9(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 30 | }); 31 | } 32 | } 33 | 34 | //1100 35 | public class L_N9 : MapLoop 36 | { 37 | public L_N9(MapLoop parentLoop) : base(parentLoop) 38 | { 39 | Content.AddRange(new MapBaseEntity[] { 40 | new N9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 41 | new SG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 42 | }); 43 | } 44 | } 45 | 46 | } 47 | } 48 | 49 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_120.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_120 : MapLoop 8 | { 9 | public M_120() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BVP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_G62(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_G62 : MapLoop 19 | { 20 | public L_G62(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new G62() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L_VC(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 25 | }); 26 | } 27 | } 28 | 29 | //1100 30 | public class L_VC : MapLoop 31 | { 32 | public L_VC(MapLoop parentLoop) : base(parentLoop) 33 | { 34 | Content.AddRange(new MapBaseEntity[] { 35 | new VC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 36 | new VC1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 37 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 38 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 39 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 40 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 41 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 42 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 43 | }); 44 | } 45 | } 46 | 47 | } 48 | } 49 | 50 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_121.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_121 : MapLoop 8 | { 9 | public M_121() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BVS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new V1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 16 | new L_VC(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_VC : MapLoop 22 | { 23 | public L_VC(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new VC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 28 | new DEL() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new CGS() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | }); 32 | } 33 | } 34 | 35 | } 36 | } 37 | 38 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_125.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_125 : MapLoop 8 | { 9 | public M_125() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BMM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new G62() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new N7() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new VC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 21 }, 16 | }); 17 | } 18 | 19 | } 20 | } 21 | 22 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_126.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_126 : MapLoop 8 | { 9 | public M_126() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_BVA(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_BVA : MapLoop 18 | { 19 | public L_BVA(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new BVA() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new V1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 24 | new L7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 25 | new L_VAD(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 26 | }); 27 | } 28 | } 29 | 30 | //1100 31 | public class L_VAD : MapLoop 32 | { 33 | public L_VAD(MapLoop parentLoop) : base(parentLoop) 34 | { 35 | Content.AddRange(new MapBaseEntity[] { 36 | new VAD() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 37 | new L7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 38 | }); 39 | } 40 | } 41 | 42 | } 43 | } 44 | 45 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_127.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_127 : MapLoop 8 | { 9 | public M_127() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BVB() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new G62() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new VC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 15 | new SFC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 16 | }); 17 | } 18 | 19 | } 20 | } 21 | 22 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_128.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_128 : MapLoop 8 | { 9 | public M_128() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 14 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 15 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new DN() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 7 }, 17 | new R9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 50 }, 18 | new DH() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 28 }, 19 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 20 | new K1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 21 | }); 22 | } 23 | 24 | } 25 | } 26 | 27 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_129.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_129 : MapLoop 8 | { 9 | public M_129() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new VR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new G62() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 3 }, 14 | new L_RT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_RT : MapLoop 20 | { 21 | public L_RT(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new RT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new RT1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 26 | }); 27 | } 28 | } 29 | 30 | } 31 | } 32 | 33 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_131.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_131 : MapLoop 8 | { 9 | public M_131() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 14 | new REF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 15 | new QTY() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 16 | new SUM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new IN2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 18 | }); 19 | } 20 | 21 | } 22 | } 23 | 24 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_139.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_139 : MapLoop 8 | { 9 | public M_139() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new GR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new DB() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new L_LM(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new L_ENT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 6 }, 17 | new L_AMT(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | }); 19 | } 20 | 21 | //1000 22 | public class L_LM : MapLoop 23 | { 24 | public L_LM(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new LM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 29 | }); 30 | } 31 | } 32 | 33 | //2000 34 | public class L_ENT : MapLoop 35 | { 36 | public L_ENT(MapLoop parentLoop) : base(parentLoop) 37 | { 38 | Content.AddRange(new MapBaseEntity[] { 39 | new ENT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 40 | new IN2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 41 | new IDB() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 42 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 43 | }); 44 | } 45 | } 46 | 47 | //3000 48 | public class L_AMT : MapLoop 49 | { 50 | public L_AMT(MapLoop parentLoop) : base(parentLoop) 51 | { 52 | Content.AddRange(new MapBaseEntity[] { 53 | new AMT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 54 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 55 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 56 | }); 57 | } 58 | } 59 | 60 | } 61 | } 62 | 63 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_144.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_144 : MapLoop 8 | { 9 | public M_144() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new GR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new LV() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 25 }, 15 | new DB() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 17 | new IDB() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 18 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 19 | new L_ENT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 20 | }); 21 | } 22 | 23 | //1000 24 | public class L_ENT : MapLoop 25 | { 26 | public L_ENT(MapLoop parentLoop) : base(parentLoop) 27 | { 28 | Content.AddRange(new MapBaseEntity[] { 29 | new ENT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 30 | new IN2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 31 | new DMG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 32 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 33 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 34 | }); 35 | } 36 | } 37 | 38 | } 39 | } 40 | 41 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_146.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_146 : MapLoop 8 | { 9 | public M_146() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new ERP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new REF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 15 | new DMG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new IND() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new SSE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 18 | new SST() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 19 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 20 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 21 | new L_IN1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 15 }, 22 | }); 23 | } 24 | 25 | //1000 26 | public class L_N1 : MapLoop 27 | { 28 | public L_N1(MapLoop parentLoop) : base(parentLoop) 29 | { 30 | Content.AddRange(new MapBaseEntity[] { 31 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 32 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 34 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 35 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 36 | }); 37 | } 38 | } 39 | 40 | //2000 41 | public class L_IN1 : MapLoop 42 | { 43 | public L_IN1(MapLoop parentLoop) : base(parentLoop) 44 | { 45 | Content.AddRange(new MapBaseEntity[] { 46 | new IN1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 47 | new IN2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 48 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 49 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 50 | }); 51 | } 52 | } 53 | 54 | } 55 | } 56 | 57 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_147.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_147 : MapLoop 8 | { 9 | public M_147() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new AAA() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new REF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 15 | new PWK() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 17 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 18 | new L_IN1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 15 }, 19 | }); 20 | } 21 | 22 | //1000 23 | public class L_N1 : MapLoop 24 | { 25 | public L_N1(MapLoop parentLoop) : base(parentLoop) 26 | { 27 | Content.AddRange(new MapBaseEntity[] { 28 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 29 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 32 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | }); 34 | } 35 | } 36 | 37 | //2000 38 | public class L_IN1 : MapLoop 39 | { 40 | public L_IN1(MapLoop parentLoop) : base(parentLoop) 41 | { 42 | Content.AddRange(new MapBaseEntity[] { 43 | new IN1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 44 | new IN2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 45 | }); 46 | } 47 | } 48 | 49 | } 50 | } 51 | 52 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_160.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_160 : MapLoop 8 | { 9 | public M_160() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BAX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new AES() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new YNQ() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 17 | new MEA() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | new AEI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 16 }, 19 | new L_EI(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 500 }, 20 | }); 21 | } 22 | 23 | //1000 24 | public class L_EI : MapLoop 25 | { 26 | public L_EI(MapLoop parentLoop) : base(parentLoop) 27 | { 28 | Content.AddRange(new MapBaseEntity[] { 29 | new EI() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 30 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 31 | new MEA() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 32 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 33 | new L_TSI(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 25 }, 34 | }); 35 | } 36 | } 37 | 38 | //1100 39 | public class L_TSI : MapLoop 40 | { 41 | public L_TSI(MapLoop parentLoop) : base(parentLoop) 42 | { 43 | Content.AddRange(new MapBaseEntity[] { 44 | new TSI() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 45 | new YNQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 25 }, 46 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 25 }, 47 | new L_QTY(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 48 | }); 49 | } 50 | } 51 | 52 | //1110 53 | public class L_QTY : MapLoop 54 | { 55 | public L_QTY(MapLoop parentLoop) : base(parentLoop) 56 | { 57 | Content.AddRange(new MapBaseEntity[] { 58 | new QTY() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 59 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 60 | }); 61 | } 62 | } 63 | 64 | } 65 | } 66 | 67 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_161.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_161 : MapLoop 8 | { 9 | public M_161() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BTS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 14 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 15 | new H3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 16 | new L_FAC(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 17 | new L_NM1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | }); 19 | } 20 | 21 | //1000 22 | public class L_FAC : MapLoop 23 | { 24 | public L_FAC(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new FAC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 29 | new H3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 30 | new PWK() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 32 | }); 33 | } 34 | } 35 | 36 | //2000 37 | public class L_NM1 : MapLoop 38 | { 39 | public L_NM1(MapLoop parentLoop) : base(parentLoop) 40 | { 41 | Content.AddRange(new MapBaseEntity[] { 42 | new NM1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 43 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 44 | }); 45 | } 46 | } 47 | 48 | } 49 | } 50 | 51 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_170.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_170 : MapLoop 8 | { 9 | public M_170() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new L_THE(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_THE : MapLoop 20 | { 21 | public L_THE(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new THE() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new L_LX(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 26 | }); 27 | } 28 | } 29 | 30 | //1100 31 | public class L_LX : MapLoop 32 | { 33 | public L_LX(MapLoop parentLoop) : base(parentLoop) 34 | { 35 | Content.AddRange(new MapBaseEntity[] { 36 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 37 | new REF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 38 | new L_DTM(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 7 }, 39 | }); 40 | } 41 | } 42 | 43 | //1110 44 | public class L_DTM : MapLoop 45 | { 46 | public L_DTM(MapLoop parentLoop) : base(parentLoop) 47 | { 48 | Content.AddRange(new MapBaseEntity[] { 49 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 50 | new BOX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 250 }, 51 | }); 52 | } 53 | } 54 | 55 | } 56 | } 57 | 58 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_188.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_188 : MapLoop 8 | { 9 | public M_188() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new ERP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 14 | new L_CSE(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_N1 : MapLoop 20 | { 21 | public L_N1(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 26 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 27 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | }); 30 | } 31 | } 32 | 33 | //2000 34 | public class L_CSE : MapLoop 35 | { 36 | public L_CSE(MapLoop parentLoop) : base(parentLoop) 37 | { 38 | Content.AddRange(new MapBaseEntity[] { 39 | new CSE() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 40 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 41 | new CSU() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 42 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 43 | new MSG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 44 | }); 45 | } 46 | } 47 | 48 | } 49 | } 50 | 51 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_213.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_213 : MapLoop 8 | { 9 | public M_213() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new B11() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new C3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new L10() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 16 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 17 | new K2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 18 | }); 19 | } 20 | 21 | //0100 22 | public class L_N1 : MapLoop 23 | { 24 | public L_N1(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 30 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 32 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 33 | }); 34 | } 35 | } 36 | 37 | } 38 | } 39 | 40 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_216.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_216 : MapLoop 8 | { 9 | public M_216() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new PUN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new TEM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_N1 : MapLoop 21 | { 22 | public L_N1(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 27 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 28 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | }); 30 | } 31 | } 32 | 33 | } 34 | } 35 | 36 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_224.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_224 : MapLoop 8 | { 9 | public M_224() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new CF1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_CF2(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 14 | }); 15 | } 16 | 17 | //0100 18 | public class L_CF2 : MapLoop 19 | { 20 | public L_CF2(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new CF2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L11() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 25 | }); 26 | } 27 | } 28 | 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_225.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_225 : MapLoop 8 | { 9 | public M_225() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new SCP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L11() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 14 | }); 15 | } 16 | 17 | } 18 | } 19 | 20 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_242.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_242 : MapLoop 8 | { 9 | public M_242() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new IRP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new MSG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new L_HL(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 18 | }); 19 | } 20 | 21 | //1000 22 | public class L_HL : MapLoop 23 | { 24 | public L_HL(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new HL() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new IIS() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 31 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 32 | new L_STS(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 33 | }); 34 | } 35 | } 36 | 37 | //1100 38 | public class L_STS : MapLoop 39 | { 40 | public L_STS(MapLoop parentLoop) : base(parentLoop) 41 | { 42 | Content.AddRange(new MapBaseEntity[] { 43 | new STS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 44 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 45 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 46 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 47 | }); 48 | } 49 | } 50 | 51 | } 52 | } 53 | 54 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_244.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_244 : MapLoop 8 | { 9 | public M_244() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_NM1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_NM1 : MapLoop 19 | { 20 | public L_NM1(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new NM1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 26 | }); 27 | } 28 | } 29 | 30 | //1100 31 | public class L_N1 : MapLoop 32 | { 33 | public L_N1(MapLoop parentLoop) : base(parentLoop) 34 | { 35 | Content.AddRange(new MapBaseEntity[] { 36 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 37 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 38 | new L_BSF(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 39 | }); 40 | } 41 | } 42 | 43 | //1110 44 | public class L_BSF : MapLoop 45 | { 46 | public L_BSF(MapLoop parentLoop) : base(parentLoop) 47 | { 48 | Content.AddRange(new MapBaseEntity[] { 49 | new BSF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 50 | new L_NX2(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 51 | new L_PID(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 52 | }); 53 | } 54 | } 55 | 56 | //1111 57 | public class L_NX2 : MapLoop 58 | { 59 | public L_NX2(MapLoop parentLoop) : base(parentLoop) 60 | { 61 | Content.AddRange(new MapBaseEntity[] { 62 | new NX2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 63 | new COM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 64 | }); 65 | } 66 | } 67 | 68 | //1112 69 | public class L_PID : MapLoop 70 | { 71 | public L_PID(MapLoop parentLoop) : base(parentLoop) 72 | { 73 | Content.AddRange(new MapBaseEntity[] { 74 | new PID() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 75 | new CID() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 76 | }); 77 | } 78 | } 79 | 80 | } 81 | } 82 | 83 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_250.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_250 : MapLoop 8 | { 9 | public M_250() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 14 | new SSD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | new L_PRF(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_PRF : MapLoop 21 | { 22 | public L_PRF(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new PRF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 27 | new FOB() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new G05() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 30 | new H3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 6 }, 31 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 32 | }); 33 | } 34 | } 35 | 36 | //0110 37 | public class L_N1 : MapLoop 38 | { 39 | public L_N1(MapLoop parentLoop) : base(parentLoop) 40 | { 41 | Content.AddRange(new MapBaseEntity[] { 42 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 43 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 44 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 45 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 46 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 47 | new G05() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 48 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 49 | }); 50 | } 51 | } 52 | 53 | } 54 | } 55 | 56 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_263.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_263 : MapLoop 8 | { 9 | public M_263() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 14 | new L_LX(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_LX : MapLoop 20 | { 21 | public L_LX(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new L_REF(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 27 | }); 28 | } 29 | } 30 | 31 | //1100 32 | public class L_REF : MapLoop 33 | { 34 | public L_REF(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new REF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 39 | new MIR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 40 | new TXI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 41 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 42 | new L_G63(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 43 | }); 44 | } 45 | } 46 | 47 | //1110 48 | public class L_G63 : MapLoop 49 | { 50 | public L_G63(MapLoop parentLoop) : base(parentLoop) 51 | { 52 | Content.AddRange(new MapBaseEntity[] { 53 | new G63() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 54 | new PCT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 55 | }); 56 | } 57 | } 58 | 59 | } 60 | } 61 | 62 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_290.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_290 : MapLoop 8 | { 9 | public M_290() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new CMA() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DOS() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 250 }, 16 | new L_MI(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 17 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 18 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 19 | }); 20 | } 21 | 22 | //1000 23 | public class L_N1 : MapLoop 24 | { 25 | public L_N1(MapLoop parentLoop) : base(parentLoop) 26 | { 27 | Content.AddRange(new MapBaseEntity[] { 28 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 29 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 32 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new ASM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 34 | }); 35 | } 36 | } 37 | 38 | //2000 39 | public class L_MI : MapLoop 40 | { 41 | public L_MI(MapLoop parentLoop) : base(parentLoop) 42 | { 43 | Content.AddRange(new MapBaseEntity[] { 44 | new MI() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 45 | new DOS() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 46 | new L_N1_1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 47 | }); 48 | } 49 | } 50 | 51 | //2100 52 | public class L_N1_1 : MapLoop 53 | { 54 | public L_N1_1(MapLoop parentLoop) : base(parentLoop) 55 | { 56 | Content.AddRange(new MapBaseEntity[] { 57 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 58 | new CRC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 59 | new PAI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 60 }, 60 | }); 61 | } 62 | } 63 | 64 | } 65 | } 66 | 67 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_303.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_303 : MapLoop 8 | { 9 | public M_303() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new B1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new Y6() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 14 | new Y5() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | }); 17 | } 18 | 19 | } 20 | } 21 | 22 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_313.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_313 : MapLoop 8 | { 9 | public M_313() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new B4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 25 }, 14 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 15 | }); 16 | } 17 | 18 | } 19 | } 20 | 21 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_315.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_315 : MapLoop 8 | { 9 | public M_315() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new B4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 30 }, 14 | new Q2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new SG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 16 | new L_R4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 17 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | }); 19 | } 20 | 21 | //1000 22 | public class L_R4 : MapLoop 23 | { 24 | public L_R4(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new R4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 29 | }); 30 | } 31 | } 32 | 33 | } 34 | } 35 | 36 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_317.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_317 : MapLoop 8 | { 9 | public M_317() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 13 | new G62() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new N9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9 }, 15 | new TD5() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 16 | new L_L0(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_N1 : MapLoop 22 | { 23 | public L_N1(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 29 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9 }, 32 | }); 33 | } 34 | } 35 | 36 | //2000 37 | public class L_L0 : MapLoop 38 | { 39 | public L_L0(MapLoop parentLoop) : base(parentLoop) 40 | { 41 | Content.AddRange(new MapBaseEntity[] { 42 | new L0() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 43 | new L5() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 44 | new H1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 45 | }); 46 | } 47 | } 48 | 49 | } 50 | } 51 | 52 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_319.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_319 : MapLoop 8 | { 9 | public M_319() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BA2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new CD1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 14 | }); 15 | } 16 | 17 | } 18 | } 19 | 20 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_323.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_323 : MapLoop 8 | { 9 | public M_323() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new V1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new K1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 14 | new L_R4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_R4 : MapLoop 20 | { 21 | public L_R4(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new R4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 26 | new V9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 5 }, 27 | }); 28 | } 29 | } 30 | 31 | } 32 | } 33 | 34 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_324.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_324 : MapLoop 8 | { 9 | public M_324() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new V1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_R4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 14 | new L_N7(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_R4 : MapLoop 20 | { 21 | public L_R4(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new R4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 26 | }); 27 | } 28 | } 29 | 30 | //2000 31 | public class L_N7 : MapLoop 32 | { 33 | public L_N7(MapLoop parentLoop) : base(parentLoop) 34 | { 35 | Content.AddRange(new MapBaseEntity[] { 36 | new N7() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 37 | new M7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 38 | new ED() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 39 | new NA() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 40 | new V4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 41 | new R4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9 }, 42 | new W09() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 43 | new H3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 6 }, 44 | new H1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 4 }, 45 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 46 | }); 47 | } 48 | } 49 | 50 | } 51 | } 52 | 53 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_326.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_326 : MapLoop 8 | { 9 | public M_326() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_V1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_V1 : MapLoop 18 | { 19 | public L_V1(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new V1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new MBL() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 24 | new G1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 26 | new VC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 27 | new L_N7(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 28 | new L_R4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 4 }, 29 | }); 30 | } 31 | } 32 | 33 | //1100 34 | public class L_N7 : MapLoop 35 | { 36 | public L_N7(MapLoop parentLoop) : base(parentLoop) 37 | { 38 | Content.AddRange(new MapBaseEntity[] { 39 | new N7() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 40 | new VC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9 }, 41 | }); 42 | } 43 | } 44 | 45 | //1200 46 | public class L_R4 : MapLoop 47 | { 48 | public L_R4(MapLoop parentLoop) : base(parentLoop) 49 | { 50 | Content.AddRange(new MapBaseEntity[] { 51 | new R4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 52 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 53 | }); 54 | } 55 | } 56 | 57 | } 58 | } 59 | 60 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_352.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_352 : MapLoop 8 | { 9 | public M_352() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new M10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_P4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_P4 : MapLoop 19 | { 20 | public L_P4(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new P4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L_M14(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 25 | }); 26 | } 27 | } 28 | 29 | //1100 30 | public class L_M14 : MapLoop 31 | { 32 | public L_M14(MapLoop parentLoop) : base(parentLoop) 33 | { 34 | Content.AddRange(new MapBaseEntity[] { 35 | new M14() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 36 | new K1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 4 }, 37 | }); 38 | } 39 | } 40 | 41 | } 42 | } 43 | 44 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_353.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_353 : MapLoop 8 | { 9 | public M_353() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new M10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new P4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new M15() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 15 | }); 16 | } 17 | 18 | } 19 | } 20 | 21 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_354.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_354 : MapLoop 8 | { 9 | public M_354() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new M10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_P4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_P4 : MapLoop 19 | { 20 | public L_P4(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new P4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new X01() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new X02() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 26 | }); 27 | } 28 | } 29 | 30 | } 31 | } 32 | 33 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_356.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_356 : MapLoop 8 | { 9 | public M_356() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new M10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_P4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_P4 : MapLoop 19 | { 20 | public L_P4(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new P4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new M20() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 25 | }); 26 | } 27 | } 28 | 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_357.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_357 : MapLoop 8 | { 9 | public M_357() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new M10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_P4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_P4 : MapLoop 19 | { 20 | public L_P4(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new P4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L_M21(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 25 | }); 26 | } 27 | } 28 | 29 | //1100 30 | public class L_M21 : MapLoop 31 | { 32 | public L_M21(MapLoop parentLoop) : base(parentLoop) 33 | { 34 | Content.AddRange(new MapBaseEntity[] { 35 | new M21() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 36 | new M12() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 37 | }); 38 | } 39 | } 40 | 41 | } 42 | } 43 | 44 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_358.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_358 : MapLoop 8 | { 9 | public M_358() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new M10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_P4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 20 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_P4 : MapLoop 19 | { 20 | public L_P4(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new P4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L_LX(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 500 }, 25 | }); 26 | } 27 | } 28 | 29 | //1100 30 | public class L_LX : MapLoop 31 | { 32 | public L_LX(MapLoop parentLoop) : base(parentLoop) 33 | { 34 | Content.AddRange(new MapBaseEntity[] { 35 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 36 | new VID() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 37 | new L_MBL(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 38 | }); 39 | } 40 | } 41 | 42 | //1110 43 | public class L_MBL : MapLoop 44 | { 45 | public L_MBL(MapLoop parentLoop) : base(parentLoop) 46 | { 47 | Content.AddRange(new MapBaseEntity[] { 48 | new MBL() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 49 | new M13() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 50 | new VID() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500 }, 51 | }); 52 | } 53 | } 54 | 55 | } 56 | } 57 | 58 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_361.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_361 : MapLoop 8 | { 9 | public M_361() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_CI(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_CI : MapLoop 19 | { 20 | public L_CI(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new CI() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new K1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | }); 26 | } 27 | } 28 | 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_414.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_414 : MapLoop 8 | { 9 | public M_414() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new LEQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 13 | new L_CTC(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_CTC : MapLoop 19 | { 20 | public L_CTC(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new CTC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L_CIC(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1000 }, 25 | }); 26 | } 27 | } 28 | 29 | //1100 30 | public class L_CIC : MapLoop 31 | { 32 | public L_CIC(MapLoop parentLoop) : base(parentLoop) 33 | { 34 | Content.AddRange(new MapBaseEntity[] { 35 | new CIC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 36 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 37 | new L_LX(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 38 | }); 39 | } 40 | } 41 | 42 | //1110 43 | public class L_LX : MapLoop 44 | { 45 | public L_LX(MapLoop parentLoop) : base(parentLoop) 46 | { 47 | Content.AddRange(new MapBaseEntity[] { 48 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 49 | new CHR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 50 | new CYC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 51 | new PRI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 52 | new L7A() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 53 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 54 | new CUR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 55 | new CV() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 56 | }); 57 | } 58 | } 59 | 60 | } 61 | } 62 | 63 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_419.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_419 : MapLoop 8 | { 9 | public M_419() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_E6(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 150 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_E6 : MapLoop 18 | { 19 | public L_E6(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new E6() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new W3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 24 | new W5() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | }); 26 | } 27 | } 28 | 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_420.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_420 : MapLoop 8 | { 9 | public M_420() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_E6(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 150 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_E6 : MapLoop 18 | { 19 | public L_E6(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new E6() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new E8() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | }); 25 | } 26 | } 27 | 28 | } 29 | } 30 | 31 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_425.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_425 : MapLoop 8 | { 9 | public M_425() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_ZT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 255 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_ZT : MapLoop 18 | { 19 | public L_ZT(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new ZT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new F9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 24 | new D9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | }); 26 | } 27 | } 28 | 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_429.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_429 : MapLoop 8 | { 9 | public M_429() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new RU1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 13 | new L_RU2(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_RU2 : MapLoop 19 | { 20 | public L_RU2(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new RU2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new RU3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 26 | }); 27 | } 28 | } 29 | 30 | } 31 | } 32 | 33 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_431.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_431 : MapLoop 8 | { 9 | public M_431() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new SMB() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 14 | new CD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new SMS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 16 | new SMA() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 17 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 18 | new SMR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 19 | new SMO() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 20 | }); 21 | } 22 | 23 | } 24 | } 25 | 26 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_432.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_432 : MapLoop 8 | { 9 | public M_432() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new BLR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 6 }, 16 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new L_LX(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | }); 19 | } 20 | 21 | //1000 22 | public class L_LX : MapLoop 23 | { 24 | public L_LX(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 8 }, 29 | new DRT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 6 }, 30 | new L_CIC(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1500 }, 31 | }); 32 | } 33 | } 34 | 35 | //1100 36 | public class L_CIC : MapLoop 37 | { 38 | public L_CIC(MapLoop parentLoop) : base(parentLoop) 39 | { 40 | Content.AddRange(new MapBaseEntity[] { 41 | new CIC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 42 | new DRT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 12 }, 43 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 44 | }); 45 | } 46 | } 47 | 48 | } 49 | } 50 | 51 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_433.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_433 : MapLoop 8 | { 9 | public M_433() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 14 | new SMS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 16 | }); 17 | } 18 | 19 | //1000 20 | public class L_N1 : MapLoop 21 | { 22 | public L_N1(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new PI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 27 | new CD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 50 }, 28 | }); 29 | } 30 | } 31 | 32 | } 33 | } 34 | 35 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_434.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_434 : MapLoop 8 | { 9 | public M_434() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BRR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 14 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 25 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_N1 : MapLoop 20 | { 21 | public L_N1(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 26 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 27 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | }); 30 | } 31 | } 32 | 33 | } 34 | } 35 | 36 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_435.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_435 : MapLoop 8 | { 9 | public M_435() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_SID(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_SID : MapLoop 18 | { 19 | public L_SID(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new SID() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 30 }, 24 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 25 | new L_LQ(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 26 | new L_LX(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 4 }, 27 | }); 28 | } 29 | } 30 | 31 | //1100 32 | public class L_LQ : MapLoop 33 | { 34 | public L_LQ(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new LQ() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new MSG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 39 | }); 40 | } 41 | } 42 | 43 | //1200 44 | public class L_LX : MapLoop 45 | { 46 | public L_LX(MapLoop parentLoop) : base(parentLoop) 47 | { 48 | Content.AddRange(new MapBaseEntity[] { 49 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 50 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 50 }, 51 | new LH3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 52 | new LH2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 8 }, 53 | new LFH() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 54 | new LEP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 55 | new LH4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 56 | new CRC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 57 | }); 58 | } 59 | } 60 | 61 | } 62 | } 63 | 64 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_436.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_436 : MapLoop 8 | { 9 | public M_436() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new LFI() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N7() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new K3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 15 | }); 16 | } 17 | 18 | } 19 | } 20 | 21 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_437.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_437 : MapLoop 8 | { 9 | public M_437() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BJF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 14 | new JCT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new L_JS(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 16 | }); 17 | } 18 | 19 | //1000 20 | public class L_JS : MapLoop 21 | { 22 | public L_JS(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new JS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 27 | new SID() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 28 | }); 29 | } 30 | } 31 | 32 | } 33 | } 34 | 35 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_440.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_440 : MapLoop 8 | { 9 | public M_440() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BW() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new G4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new G5() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 255 }, 15 | }); 16 | } 17 | 18 | } 19 | } 20 | 21 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_451.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_451 : MapLoop 8 | { 9 | public M_451() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new ER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 13 | new L_ED(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_ED : MapLoop 19 | { 20 | public L_ED(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new ED() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new ER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 25 | new NA() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 26 | new IC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 27 | new CLR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 28 | new ES() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | }); 30 | } 31 | } 32 | 33 | } 34 | } 35 | 36 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_452.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_452 : MapLoop 8 | { 9 | public M_452() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 15 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 16 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 17 | }); 18 | } 19 | 20 | } 21 | } 22 | 23 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_453.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_453 : MapLoop 8 | { 9 | public M_453() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new SSC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 14 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | new R2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 13 }, 16 | new OD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new PI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | new PR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 19 | new CT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 20 | new APR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 21 | new SHR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 22 | new L_SR(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 7 }, 23 | }); 24 | } 25 | 26 | //1000 27 | public class L_SR : MapLoop 28 | { 29 | public L_SR(MapLoop parentLoop) : base(parentLoop) 30 | { 31 | Content.AddRange(new MapBaseEntity[] { 32 | new SR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 33 | new L_LX(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 34 | }); 35 | } 36 | } 37 | 38 | //1100 39 | public class L_LX : MapLoop 40 | { 41 | public L_LX(MapLoop parentLoop) : base(parentLoop) 42 | { 43 | Content.AddRange(new MapBaseEntity[] { 44 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 45 | new ISD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 15 }, 46 | new ISC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 47 | }); 48 | } 49 | } 50 | 51 | } 52 | } 53 | 54 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_455.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_455 : MapLoop 8 | { 9 | public M_455() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BTC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new ED() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500000 }, 15 | new BLR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 16 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 18 | new L_LX(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 19 | }); 20 | } 21 | 22 | //1000 23 | public class L_LX : MapLoop 24 | { 25 | public L_LX(MapLoop parentLoop) : base(parentLoop) 26 | { 27 | Content.AddRange(new MapBaseEntity[] { 28 | new LX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 29 | new PRM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new F9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 32 | new D9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 34 | }); 35 | } 36 | } 37 | 38 | } 39 | } 40 | 41 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_463.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_463 : MapLoop 8 | { 9 | public M_463() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new REN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_DK(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 300000 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_DK : MapLoop 19 | { 20 | public L_DK(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new DK() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new L_LQ(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 25 | }); 26 | } 27 | } 28 | 29 | //1100 30 | public class L_LQ : MapLoop 31 | { 32 | public L_LQ(MapLoop parentLoop) : base(parentLoop) 33 | { 34 | Content.AddRange(new MapBaseEntity[] { 35 | new LQ() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 36 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 37 | }); 38 | } 39 | } 40 | 41 | } 42 | } 43 | 44 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_466.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_466 : MapLoop 8 | { 9 | public M_466() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new REN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DK() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new PR1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new PR2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new PI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | }); 18 | } 19 | 20 | } 21 | } 22 | 23 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_468.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_468 : MapLoop 8 | { 9 | public M_468() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new DK() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_JL(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 7 }, 14 | }); 15 | } 16 | 17 | //0100 18 | public class L_JL : MapLoop 19 | { 20 | public L_JL(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new JL() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new K1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 100 }, 25 | }); 26 | } 27 | } 28 | 29 | } 30 | } 31 | 32 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_475.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_475 : MapLoop 8 | { 9 | public M_475() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_R9(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 50 }, 14 | }); 15 | } 16 | 17 | //1000 18 | public class L_R9 : MapLoop 19 | { 20 | public L_R9(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new R9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 26 | new RDD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 27 | }); 28 | } 29 | } 30 | 31 | } 32 | } 33 | 34 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_485.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_485 : MapLoop 8 | { 9 | public M_485() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new DK() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new PRI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new SA() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new L_SC(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 8 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_SC : MapLoop 21 | { 22 | public L_SC(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new SC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new L_RA(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 27 | }); 28 | } 29 | } 30 | 31 | //0110 32 | public class L_RA : MapLoop 33 | { 34 | public L_RA(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new RA() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new FK() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 39 | new L_MC(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 64 }, 40 | new SW() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 41 | }); 42 | } 43 | } 44 | 45 | //0111 46 | public class L_MC : MapLoop 47 | { 48 | public L_MC(MapLoop parentLoop) : base(parentLoop) 49 | { 50 | Content.AddRange(new MapBaseEntity[] { 51 | new MC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 52 | new FK() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 53 | }); 54 | } 55 | } 56 | 57 | } 58 | } 59 | 60 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_486.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_486 : MapLoop 8 | { 9 | public M_486() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new REN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new PI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new SA() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 16 | }); 17 | } 18 | 19 | } 20 | } 21 | 22 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_490.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_490 : MapLoop 8 | { 9 | public M_490() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new REN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DK() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new GH() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new PI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 8 }, 16 | new TT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500 }, 17 | new GY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500 }, 18 | new CD() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500 }, 19 | new PR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500 }, 20 | new L_PT(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 500 }, 21 | }); 22 | } 23 | 24 | //1000 25 | public class L_PT : MapLoop 26 | { 27 | public L_PT(MapLoop parentLoop) : base(parentLoop) 28 | { 29 | Content.AddRange(new MapBaseEntity[] { 30 | new PT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 31 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 32 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 34 | }); 35 | } 36 | } 37 | 38 | } 39 | } 40 | 41 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_492.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_492 : MapLoop 8 | { 9 | public M_492() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new DK() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new PRI() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new DM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new L_SC(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_SC : MapLoop 21 | { 22 | public L_SC(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new SC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new DM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 27 | }); 28 | } 29 | } 30 | 31 | } 32 | } 33 | 34 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_504.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_504 : MapLoop 8 | { 9 | public M_504() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 14 | new L_REF(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_N1 : MapLoop 20 | { 21 | public L_N1(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 26 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 27 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 29 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 30 | new L_LM(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 31 | }); 32 | } 33 | } 34 | 35 | //1100 36 | public class L_LM : MapLoop 37 | { 38 | public L_LM(MapLoop parentLoop) : base(parentLoop) 39 | { 40 | Content.AddRange(new MapBaseEntity[] { 41 | new LM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 42 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 43 | }); 44 | } 45 | } 46 | 47 | //2000 48 | public class L_REF : MapLoop 49 | { 50 | public L_REF(MapLoop parentLoop) : base(parentLoop) 51 | { 52 | Content.AddRange(new MapBaseEntity[] { 53 | new REF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 54 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 55 | new MSG() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 56 | new L_LM_1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 57 | }); 58 | } 59 | } 60 | 61 | //2100 62 | public class L_LM_1 : MapLoop 63 | { 64 | public L_LM_1(MapLoop parentLoop) : base(parentLoop) 65 | { 66 | Content.AddRange(new MapBaseEntity[] { 67 | new LM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 68 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 69 | }); 70 | } 71 | } 72 | 73 | } 74 | } 75 | 76 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_567.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_567 : MapLoop 8 | { 9 | public M_567() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 14 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 16 | new L_CS(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 100 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_CS : MapLoop 22 | { 23 | public L_CS(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new CS() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 28 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 30 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 32 | new L_LM(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 33 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 34 | }); 35 | } 36 | } 37 | 38 | //1100 39 | public class L_LM : MapLoop 40 | { 41 | public L_LM(MapLoop parentLoop) : base(parentLoop) 42 | { 43 | Content.AddRange(new MapBaseEntity[] { 44 | new LM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 45 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 46 | }); 47 | } 48 | } 49 | 50 | //1200 51 | public class L_N1 : MapLoop 52 | { 53 | public L_N1(MapLoop parentLoop) : base(parentLoop) 54 | { 55 | Content.AddRange(new MapBaseEntity[] { 56 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 57 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 58 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 59 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 60 | }); 61 | } 62 | } 63 | 64 | } 65 | } 66 | 67 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_715.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_715 : MapLoop 8 | { 9 | public M_715() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new GR2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new V1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new L_GR4(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 100 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_GR4 : MapLoop 22 | { 23 | public L_GR4(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new GR4() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 28 | new L_N7(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 29 | }); 30 | } 31 | } 32 | 33 | //1100 34 | public class L_N7 : MapLoop 35 | { 36 | public L_N7(MapLoop parentLoop) : base(parentLoop) 37 | { 38 | Content.AddRange(new MapBaseEntity[] { 39 | new N7() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 40 | new GR5() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 41 | new V1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 42 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 43 | new R4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 44 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 45 | }); 46 | } 47 | } 48 | 49 | } 50 | } 51 | 52 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_815.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_815 : MapLoop 8 | { 9 | public M_815() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new CSM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new CSB() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 14 | new L_CSC(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_CSC : MapLoop 20 | { 21 | public L_CSC(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new CSC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new DTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9 }, 26 | }); 27 | } 28 | } 29 | 30 | } 31 | } 32 | 33 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_827.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_827 : MapLoop 8 | { 9 | public M_827() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new RIC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new TRN() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 14 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 16 | new L_NM1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_NM1 : MapLoop 22 | { 23 | public L_NM1(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new NM1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 28 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 29 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 31 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 32 | }); 33 | } 34 | } 35 | 36 | } 37 | } 38 | 39 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_828.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_828 : MapLoop 8 | { 9 | public M_828() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BAU() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 16 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 18 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 19 | new L_DAD(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 20 | new CTT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 21 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 22 | }); 23 | } 24 | 25 | //1000 26 | public class L_DAD : MapLoop 27 | { 28 | public L_DAD(MapLoop parentLoop) : base(parentLoop) 29 | { 30 | Content.AddRange(new MapBaseEntity[] { 31 | new DAD() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 32 | new NM1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 34 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 35 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 36 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 37 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 38 | }); 39 | } 40 | } 41 | 42 | } 43 | } 44 | 45 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_829.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_829 : MapLoop 8 | { 9 | public M_829() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new PCR() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new TRN() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 14 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 15 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 17 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | }); 19 | } 20 | 21 | } 22 | } 23 | 24 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_831.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_831 : MapLoop 8 | { 9 | public M_831() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 14 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 15 | new TRN() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 16 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 17 | new L_AMT(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 18 | }); 19 | } 20 | 21 | //1000 22 | public class L_AMT : MapLoop 23 | { 24 | public L_AMT(MapLoop parentLoop) : base(parentLoop) 25 | { 26 | Content.AddRange(new MapBaseEntity[] { 27 | new AMT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | }); 30 | } 31 | } 32 | 33 | } 34 | } 35 | 36 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_864.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_864 : MapLoop 8 | { 9 | public M_864() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BMG() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 14 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 200 }, 15 | new L_MIT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 16 | }); 17 | } 18 | 19 | //1000 20 | public class L_N1 : MapLoop 21 | { 22 | public L_N1(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 27 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 28 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 12 }, 30 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 31 | }); 32 | } 33 | } 34 | 35 | //2000 36 | public class L_MIT : MapLoop 37 | { 38 | public L_MIT(MapLoop parentLoop) : base(parentLoop) 39 | { 40 | Content.AddRange(new MapBaseEntity[] { 41 | new MIT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 42 | new L_N1_1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 200 }, 43 | new MSG() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 100000 }, 44 | }); 45 | } 46 | } 47 | 48 | //2100 49 | public class L_N1_1 : MapLoop 50 | { 51 | public L_N1_1(MapLoop parentLoop) : base(parentLoop) 52 | { 53 | Content.AddRange(new MapBaseEntity[] { 54 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 55 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 56 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 57 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 58 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 12 }, 59 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 60 | }); 61 | } 62 | } 63 | 64 | } 65 | } 66 | 67 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_877.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_877 : MapLoop 8 | { 9 | public M_877() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 3 }, 14 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | new L_ENT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_ENT : MapLoop 21 | { 22 | public L_ENT(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new ENT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new L_LIN(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 27 | }); 28 | } 29 | } 30 | 31 | //0110 32 | public class L_LIN : MapLoop 33 | { 34 | public L_LIN(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new LIN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new L_G28(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 39 | }); 40 | } 41 | } 42 | 43 | //0111 44 | public class L_G28 : MapLoop 45 | { 46 | public L_G28(MapLoop parentLoop) : base(parentLoop) 47 | { 48 | Content.AddRange(new MapBaseEntity[] { 49 | new G28() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 50 | new G69() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 51 | }); 52 | } 53 | } 54 | 55 | } 56 | } 57 | 58 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_878.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_878 : MapLoop 8 | { 9 | public M_878() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 13 | new L_G21(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 14 | }); 15 | } 16 | 17 | //0100 18 | public class L_N1 : MapLoop 19 | { 20 | public L_N1(MapLoop parentLoop) : base(parentLoop) 21 | { 22 | Content.AddRange(new MapBaseEntity[] { 23 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 24 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 26 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 27 | }); 28 | } 29 | } 30 | 31 | //0200 32 | public class L_G21 : MapLoop 33 | { 34 | public L_G21(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new G21() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new G69() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 39 | new L_N1_1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 250 }, 40 | }); 41 | } 42 | } 43 | 44 | //0210 45 | public class L_N1_1 : MapLoop 46 | { 47 | public L_N1_1(MapLoop parentLoop) : base(parentLoop) 48 | { 49 | Content.AddRange(new MapBaseEntity[] { 50 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 51 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 52 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 53 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 54 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 55 | new G22() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 56 | }); 57 | } 58 | } 59 | 60 | } 61 | } 62 | 63 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_882.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_882 : MapLoop 8 | { 9 | public M_882() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new G47() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 14 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 8 }, 16 | new G23() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 17 | new L_G48(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 18 | new G49() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 19 | }); 20 | } 21 | 22 | //0100 23 | public class L_N1 : MapLoop 24 | { 25 | public L_N1(MapLoop parentLoop) : base(parentLoop) 26 | { 27 | Content.AddRange(new MapBaseEntity[] { 28 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 29 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 31 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 32 | }); 33 | } 34 | } 35 | 36 | //0200 37 | public class L_G48 : MapLoop 38 | { 39 | public L_G48(MapLoop parentLoop) : base(parentLoop) 40 | { 41 | Content.AddRange(new MapBaseEntity[] { 42 | new G48() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 43 | new L_G72(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 44 | new G23() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 45 | new G25() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 46 | new G31() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 47 | new G33() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 48 | }); 49 | } 50 | } 51 | 52 | //0210 53 | public class L_G72 : MapLoop 54 | { 55 | public L_G72(MapLoop parentLoop) : base(parentLoop) 56 | { 57 | Content.AddRange(new MapBaseEntity[] { 58 | new G72() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 59 | new G73() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 60 | }); 61 | } 62 | } 63 | 64 | } 65 | } 66 | 67 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_884.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_884 : MapLoop 8 | { 9 | public M_884() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BMP() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 5 }, 14 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 15 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new BAL() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 18 | new L_N9(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 19 | }); 20 | } 21 | 22 | //0100 23 | public class L_N9 : MapLoop 24 | { 25 | public L_N9(MapLoop parentLoop) : base(parentLoop) 26 | { 27 | Content.AddRange(new MapBaseEntity[] { 28 | new N9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 29 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | }); 32 | } 33 | } 34 | 35 | } 36 | } 37 | 38 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_885.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_885 : MapLoop 8 | { 9 | public M_885() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 3 }, 13 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 15 | new L_ENT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_ENT : MapLoop 21 | { 22 | public L_ENT(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new ENT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new G53() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new DTM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 28 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 30 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 32 | new N1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 33 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 34 | new G13() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 35 | new G18() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 30 }, 36 | new G29() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 37 | new G30() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 38 | new SPR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 39 | new RDI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 40 | new L_LM(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 41 | }); 42 | } 43 | } 44 | 45 | //0110 46 | public class L_LM : MapLoop 47 | { 48 | public L_LM(MapLoop parentLoop) : base(parentLoop) 49 | { 50 | Content.AddRange(new MapBaseEntity[] { 51 | new LM() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 52 | new LQ() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 53 | }); 54 | } 55 | } 56 | 57 | } 58 | } 59 | 60 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_886.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_886 : MapLoop 8 | { 9 | public M_886() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 13 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 14 | new L_ENT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 5000 }, 15 | }); 16 | } 17 | 18 | //0100 19 | public class L_ENT : MapLoop 20 | { 21 | public L_ENT(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new ENT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new DTM() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 26 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 150 }, 27 | }); 28 | } 29 | } 30 | 31 | //0110 32 | public class L_N1 : MapLoop 33 | { 34 | public L_N1(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new G32() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 25 }, 39 | new G37() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 40 | new L_G28(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1000 }, 41 | }); 42 | } 43 | } 44 | 45 | //0111 46 | public class L_G28 : MapLoop 47 | { 48 | public L_G28(MapLoop parentLoop) : base(parentLoop) 49 | { 50 | Content.AddRange(new MapBaseEntity[] { 51 | new G28() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 52 | new QTY() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 53 | new G29() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 54 | new CTP() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 4 }, 55 | new G35() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 56 | new CRC() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 57 | }); 58 | } 59 | } 60 | 61 | } 62 | } 63 | 64 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_891.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_891 : MapLoop 8 | { 9 | public M_891() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGN() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 2 }, 14 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 15 | new L_ENT(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 100 }, 16 | }); 17 | } 18 | 19 | //0100 20 | public class L_ENT : MapLoop 21 | { 22 | public L_ENT(MapLoop parentLoop) : base(parentLoop) 23 | { 24 | Content.AddRange(new MapBaseEntity[] { 25 | new ENT() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 26 | new L_N9(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 27 | }); 28 | } 29 | } 30 | 31 | //0110 32 | public class L_N9 : MapLoop 33 | { 34 | public L_N9(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new N9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 39 | new L_ADX(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1000 }, 40 | }); 41 | } 42 | } 43 | 44 | //0111 45 | public class L_ADX : MapLoop 46 | { 47 | public L_ADX(MapLoop parentLoop) : base(parentLoop) 48 | { 49 | Content.AddRange(new MapBaseEntity[] { 50 | new ADX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 51 | new AMT() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 52 | new REF() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 53 | }); 54 | } 55 | } 56 | 57 | } 58 | } 59 | 60 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_893.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_893 : MapLoop 8 | { 9 | public M_893() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new G39() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 13 | new G69() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 15 | }); 16 | } 17 | 18 | //0100 19 | public class L_N1 : MapLoop 20 | { 21 | public L_N1(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 26 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 27 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 28 | }); 29 | } 30 | } 31 | 32 | } 33 | } 34 | 35 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_894.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_894 : MapLoop 8 | { 9 | public M_894() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new G82() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 14 | new LS() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new L_G83(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 16 | new LE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new G72() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 18 | new G23() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 19 | new G84() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 20 | new G86() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 21 | new G85() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 22 | }); 23 | } 24 | 25 | //0100 26 | public class L_G83 : MapLoop 27 | { 28 | public L_G83(MapLoop parentLoop) : base(parentLoop) 29 | { 30 | Content.AddRange(new MapBaseEntity[] { 31 | new G83() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 32 | new G22() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new G72() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 34 | new G23() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 35 | }); 36 | } 37 | } 38 | 39 | } 40 | } 41 | 42 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_895.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_895 : MapLoop 8 | { 9 | public M_895() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new G87() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new G88() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new LS() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new L_G89(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 16 | new LE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 17 | new G72() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 18 | new G23() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 19 | new G84() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 20 | new G86() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 21 | new G85() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 22 | }); 23 | } 24 | 25 | //0100 26 | public class L_G89 : MapLoop 27 | { 28 | public L_G89(MapLoop parentLoop) : base(parentLoop) 29 | { 30 | Content.AddRange(new MapBaseEntity[] { 31 | new G89() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 32 | new G22() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 33 | new G72() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 34 | new G23() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 35 | }); 36 | } 37 | } 38 | 39 | } 40 | } 41 | 42 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_896.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_896 : MapLoop 8 | { 9 | public M_896() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 14 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 15 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 17 | new G43() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 200 }, 18 | new L_ID1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999 }, 19 | }); 20 | } 21 | 22 | //0100 23 | public class L_N1 : MapLoop 24 | { 25 | public L_N1(MapLoop parentLoop) : base(parentLoop) 26 | { 27 | Content.AddRange(new MapBaseEntity[] { 28 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 29 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 30 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 31 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 32 | }); 33 | } 34 | } 35 | 36 | //0200 37 | public class L_ID1 : MapLoop 38 | { 39 | public L_ID1(MapLoop parentLoop) : base(parentLoop) 40 | { 41 | Content.AddRange(new MapBaseEntity[] { 42 | new ID1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 43 | new ID2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 44 | new ID3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 50 }, 45 | }); 46 | } 47 | } 48 | 49 | } 50 | } 51 | 52 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_920.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_920 : MapLoop 8 | { 9 | public M_920() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new F01() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 14 | new CUR() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 15 | new L_N1(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 16 | new L_F02(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 17 | }); 18 | } 19 | 20 | //1000 21 | public class L_N1 : MapLoop 22 | { 23 | public L_N1(MapLoop parentLoop) : base(parentLoop) 24 | { 25 | Content.AddRange(new MapBaseEntity[] { 26 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 27 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 28 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 29 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 30 | }); 31 | } 32 | } 33 | 34 | //2000 35 | public class L_F02 : MapLoop 36 | { 37 | public L_F02(MapLoop parentLoop) : base(parentLoop) 38 | { 39 | Content.AddRange(new MapBaseEntity[] { 40 | new F02() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 41 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 42 | new MAN() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 43 | new F05() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 44 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 30 }, 45 | new Q7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 46 | new M7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 47 | new L_F09(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 100 }, 48 | }); 49 | } 50 | } 51 | 52 | //2100 53 | public class L_F09 : MapLoop 54 | { 55 | public L_F09(MapLoop parentLoop) : base(parentLoop) 56 | { 57 | Content.AddRange(new MapBaseEntity[] { 58 | new F09() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 59 | new F04() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 60 | new F05() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 61 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 9999 }, 62 | }); 63 | } 64 | } 65 | 66 | } 67 | } 68 | 69 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_924.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_924 : MapLoop 8 | { 9 | public M_924() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new F01() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new F6X() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 14 | new F02() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 15 | new F12() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new F07() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 17 | }); 18 | } 19 | 20 | } 21 | } 22 | 23 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_925.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_925 : MapLoop 8 | { 9 | public M_925() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_F10(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 99 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_F10 : MapLoop 18 | { 19 | public L_F10(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new F10() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new F02() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 24 | }); 25 | } 26 | } 27 | 28 | } 29 | } 30 | 31 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_926.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_926 : MapLoop 8 | { 9 | public M_926() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new L_F11(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 500 }, 13 | }); 14 | } 15 | 16 | //1000 17 | public class L_F11 : MapLoop 18 | { 19 | public L_F11(MapLoop parentLoop) : base(parentLoop) 20 | { 21 | Content.AddRange(new MapBaseEntity[] { 22 | new F11() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | new F14() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 24 | new TRN() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 25 | new F13() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 26 | }); 27 | } 28 | } 29 | 30 | } 31 | } 32 | 33 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_928.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_928 : MapLoop 8 | { 9 | public M_928() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BIX() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new TI() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new L_VC(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 21 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_VC : MapLoop 20 | { 21 | public L_VC(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new VC() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new ID() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 26 | }); 27 | } 28 | } 29 | 30 | } 31 | } 32 | 33 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_943.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_943 : MapLoop 8 | { 9 | public M_943() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new W06() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_N1(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 14 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 15 | new G61() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 3 }, 16 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 17 | new NTE() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 20 }, 18 | new W27() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 19 | new W28() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 20 | new W10() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 21 | new L_W04(this) { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 9999 }, 22 | new W03() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 23 | }); 24 | } 25 | 26 | //0100 27 | public class L_N1 : MapLoop 28 | { 29 | public L_N1(MapLoop parentLoop) : base(parentLoop) 30 | { 31 | Content.AddRange(new MapBaseEntity[] { 32 | new N1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 33 | new N2() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 34 | new N3() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 35 | new N4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 36 | new PER() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 37 | }); 38 | } 39 | } 40 | 41 | //0200 42 | public class L_W04 : MapLoop 43 | { 44 | public L_W04(MapLoop parentLoop) : base(parentLoop) 45 | { 46 | Content.AddRange(new MapBaseEntity[] { 47 | new W04() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 48 | new G69() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 5 }, 49 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 200 }, 50 | new W20() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 2 }, 51 | }); 52 | } 53 | } 54 | 55 | } 56 | } 57 | 58 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_980.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_980 : MapLoop 8 | { 9 | public M_980() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BT1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 10 }, 13 | }); 14 | } 15 | 16 | } 17 | } 18 | 19 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_990.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_990 : MapLoop 8 | { 9 | public M_990() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new B1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 14 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 6 }, 15 | new N7() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 16 | new L9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 40 }, 17 | new V9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 18 | new K1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 19 | new L_S5(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999 }, 20 | }); 21 | } 22 | 23 | //0100 24 | public class L_S5 : MapLoop 25 | { 26 | public L_S5(MapLoop parentLoop) : base(parentLoop) 27 | { 28 | Content.AddRange(new MapBaseEntity[] { 29 | new S5() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 30 | new N9() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 31 | new G62() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 32 | new K1() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 10 }, 33 | }); 34 | } 35 | } 36 | 37 | } 38 | } 39 | 40 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_996.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_996 : MapLoop 8 | { 9 | public M_996() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new BGF() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new K3() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 999999 }, 14 | }); 15 | } 16 | 17 | } 18 | } 19 | 20 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_997.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_997 : MapLoop 8 | { 9 | public M_997() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new AK1() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | new L_AK2(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 14 | new AK9() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 15 | }); 16 | } 17 | 18 | //1000 19 | public class L_AK2 : MapLoop 20 | { 21 | public L_AK2(MapLoop parentLoop) : base(parentLoop) 22 | { 23 | Content.AddRange(new MapBaseEntity[] { 24 | new AK2() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 25 | new L_AK3(this) { ReqDes = RequirementDesignator.Optional, MaxOccurs = 999999 }, 26 | new AK5() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 1 }, 27 | }); 28 | } 29 | } 30 | 31 | //1100 32 | public class L_AK3 : MapLoop 33 | { 34 | public L_AK3(MapLoop parentLoop) : base(parentLoop) 35 | { 36 | Content.AddRange(new MapBaseEntity[] { 37 | new AK3() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 38 | new AK4() { ReqDes = RequirementDesignator.Optional, MaxOccurs = 99 }, 39 | }); 40 | } 41 | } 42 | 43 | } 44 | } 45 | 46 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/Maps/M_998.cs: -------------------------------------------------------------------------------- 1 | using EdiEngine.Common.Enums; 2 | using EdiEngine.Common.Definitions; 3 | using EdiEngine.Standards.X12_004010.Segments; 4 | 5 | namespace EdiEngine.Standards.X12_004010.Maps 6 | { 7 | public class M_998 : MapLoop 8 | { 9 | public M_998() : base(null) 10 | { 11 | Content.AddRange(new MapBaseEntity[] { 12 | new ZD() { ReqDes = RequirementDesignator.Mandatory, MaxOccurs = 1 }, 13 | }); 14 | } 15 | 16 | } 17 | } 18 | 19 | -------------------------------------------------------------------------------- /EdiStandards/X12_004010/X12_004010.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | netstandard2.0 5 | EdiEngine.Standards.X12_004010 6 | EdiEngine.Standards.X12_004010 7 | 1.6.0.0 8 | 1.6.0.0 9 | 1.6.0.0 10 | Edi Engine X12 004010 lib 11 | https://github.com/olmelabs/EdiEngine 12 | https://github.com/olmelabs/EdiEngine 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 olmelabs 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # EdiEngine 2 | Simple .NET EDI Reader, Writer and Validator. 3 | Read, Write and Validate X12 EDI files with simple EDI Parser written on C#. 4 | Main Features: 5 | * **EDI to JSON and JSON to EDI conversion**. 6 | EdiEngine uses Newtonsoft Json for serialization, and raw Newtonsoft Json reader for Deserialization. Json is a handy extension for the library. Imagine you can parse your EDI object directly in Angular or JQuery app. 7 | * **EDI to XML and XML to EDI conversion**. EdiEngine does not use XML as intermediate format, as many other engines do. 8 | It uses POCO objects and XML is just an extension 9 | * **Configurable EDI X12 997 - Functional Acknowledgment** generation. You can setup whether to accept all messages, accept but say errors were noted or reject depending on your needs. 10 | * **HL Loop Hierarchical parsing** - Create real tree structure basing on HL segment hierarchy. No need to map every HL to map, this means one map can serve multiple needs. Say for ASN it can be S-O-P-I or S-O-I hierarchy in one map. 11 | * **Syntax Notes**. All types of [EDI Syntax notes](https://github.com/olmelabs/EdiEngine/wiki/Syntax-Notes) are supported. P Paired, R Required, E Exclusion, C Conditional, L List Conditional 12 | * **Composite Data Elements** are supported, which is really important for HIPAA and sometimes for other transactions even in retail. 13 | * **X12 Maps** Current repository contains all 004010 maps, including Purchase Order, Invoice, Shipment and many others. 14 | You can easily craft yours on their basis. 15 | * **.NET Standard 2.0 and Source Linking**. From version 1.6 repository only contains .NET Standard 2.0 projects. Source linking enabled and symbol package is published to nuget symbols server, making debugging easier. If you need a projects targeted .NET 4.5, use version 1.5.2 (no sourcelink and symbols available). 16 | 17 | ## Installation 18 | Clone repository or Install Nuget Package 19 | ``` 20 | Install-Package xEdi.EdiEngine 21 | ``` 22 | ## How To's 23 | Please use [Wiki](https://github.com/olmelabs/EdiEngine/wiki) for documentation and usage examples. 24 | 25 | #### Complete usage examples can be found in the test project #### 26 | Note - test project is not a part of nuget package. You have to clone repository. 27 | 28 | ## Roadmap: 29 | - ~~Json Serialization and Deserialization~~ 30 | - ~~Xml Serialization and Deserialization~~ 31 | - ~~Craft more maps~~ (Added all 004010 maps) 32 | - ~~997 generation~~ 33 | - ~~HL loop hierarchical parsing~~ 34 | - ~~Syntax Notes~~ 35 | - ~~Composite data elements~~ 36 | - ~~.NET Core support~~ 37 | - HIPAA support 38 | 39 | -------------------------------------------------------------------------------- /ReleaseNotes.txt: -------------------------------------------------------------------------------- 1 | 1.0.0 - 09 Nov 2017 2 | Initial Release. 3 | 4 | 1.1.0 - 13 Nov 2017 5 | Added XML Serialization and Deserialization. 6 | 7 | 1.2.0 - 15 Nov 2017 8 | Maps repository now contains all 004010 maps, including Purchase Order, Invoice and many others. You can easily craft yours on their basis. 9 | 10 | 1.2.1 - 16 Nov 2017 11 | Added libs for .NET 4.5. to Nuget package. 12 | 13 | 1.3.0 - 20 Nov 2017 14 | Added EDI 997 - Functional Acknowledgment generation. 15 | 16 | 1.3.1 - 28 Nov 2017 17 | Added HL Loop Hierarchical parsing. 18 | 19 | 1.3.2 - 29 Nov 2017 20 | Added ability to use external map assembly. 21 | 22 | 1.5.0 - 6 Dec 2017 23 | Implemented Syntax Notes and their validation in EdiReader. 24 | Added segment level validation (elements and syntax notes) to EdiWriter. 25 | Implemented composite data elements. 26 | Maps updated with composites and syntax notes. 27 | Bugfixes. 28 | 29 | 1.5.1 - 23 Jan 2018 30 | Added NetStandard 2.0 targeted libraries. 31 | 32 | 1.5.2 - 28 Aug 2018 33 | Added B (Binary) data type. 34 | Fixed Time validation parsing for 24h format. 35 | 36 | 1.6.0 - 4 July 2020 37 | Added Sourcelink. 38 | Bugfix in Date Time validation. 39 | Package updates. 40 | Only netstandard2 is now supported. 41 | -------------------------------------------------------------------------------- /_nuget/config.nuspec: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | xEdi.EdiEngine 5 | 1.6.0 6 | olmelabs 7 | olmelabs 8 | false 9 | MIT 10 | https://github.com/olmelabs/EdiEngine 11 | 12 | 13 | Added Sourcelink. 14 | Bugfix in Date Time validation. 15 | Package updates. 16 | Only netstandard2 is now supported. 17 | 18 | Simple .NET EDI X12 Reader, Writer and Validator. EDI JSON and XML Serialization and Deserialization. 19 | .NET EDI X12 JSON XML EdiReader EdiWriter EdiParser EdiXml EdiJson FunctionalAcknowledgment SyntaxNotes NetCore 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | -------------------------------------------------------------------------------- /_nuget/pkg.bat: -------------------------------------------------------------------------------- 1 | dotnet build --configuration release ..\EdiEngine.sln 2 | nuget.exe pack config.nuspec -Symbols -SymbolPackageFormat snupkg 3 | -------------------------------------------------------------------------------- /_nuget/pushSymbols.bat: -------------------------------------------------------------------------------- 1 | nuget push xEdi.EdiEngine.1.6.0.snupkg --------------------------------------------------------------------------------