private StepFile ReadFileFromHeader(string header) { var file = $@" {StepFile.MagicHeader}; {StepFile.HeaderText}; {header.Trim()} {StepFile.EndSectionText}; {StepFile.DataText}; {StepFile.EndSectionText}; {StepFile.MagicFooter}; "; return(StepFile.Parse(file.Trim())); }
private StepFile ReadFile(string data) { var text = $@" ISO-10303-21; HEADER; ENDSEC; DATA; {data.Trim()} ENDSEC; END-ISO-10303-21; "; var file = StepFile.Parse(text.Trim()); return(file); }