Esempio n. 1
0
        public static List <X12> ParseText(string text, X12Factory factory)
        {
            var segments = text.Split(new[] { '~' }, StringSplitOptions.RemoveEmptyEntries);
            var list     = new List <X12>();

            foreach (var segment in segments)
            {
                var obj = factory.GetX12Item(segment.Trim());
                list.Add(obj);
            }
            return(list);
        }
Esempio n. 2
0
        public static List <X12> Parse(string fileName, X12Factory factory)
        {
            var text = File.ReadAllText(fileName);

            return(ParseText(text, factory));
        }
Esempio n. 3
0
        public static List <X12> Parse(string fileName)
        {
            var factory = new X12Factory(typeof(X12));

            return(Parse(fileName, factory));
        }
Esempio n. 4
0
        public static List <X12> ParseText(string text)
        {
            var factory = new X12Factory(typeof(X12));

            return(ParseText(text, factory));
        }