/// <summary> /// Copy constructor.<br> /// Initializes the components list with a deep copy of the source components list. </summary> /// <param name="source"> a field instance to copy /// @since 7.7 </param> public static Field29A newInstance(Field29A source) { Field29A cp = new Field29A(); cp.Components = new List <>(source.Components); return(cp); }
public static Field29A fromJson(string json) { Field29A field = new Field29A(); JsonParser parser = new JsonParser(); JsonObject jsonObject = (JsonObject)parser.parse(json); if (jsonObject.get("narrative") != null) { field.Component1 = jsonObject.get("narrative").AsString; } if (jsonObject.get("narrative2") != null) { field.Component2 = jsonObject.get("narrative2").AsString; } if (jsonObject.get("narrative3") != null) { field.Component3 = jsonObject.get("narrative3").AsString; } if (jsonObject.get("narrative4") != null) { field.Component4 = jsonObject.get("narrative4").AsString; } return(field); }
public virtual IList <string> getLinesBetween(int start, int end, int offset) { Field29A cp = newInstance(this); return(SwiftParseUtils.getLines(getLine(cp, start, end, offset))); }
public virtual IList <string> getLines(int offset) { Field29A cp = newInstance(this); return(SwiftParseUtils.getLines(getLine(cp, null, null, offset))); }
public virtual string getLine(int line, int offset) { Field29A cp = newInstance(this); return(getLine(cp, line, null, offset)); }