internal void loadFields(FieldsOwner owner) { if (owner is Order) { Order o = (Order)owner; foreach (SchemaFieldDefinition sdf in o.parent.emsxapi.orderFields) { Field f = new Field(this, sdf.name, ""); fields.Add(f); } } else if (owner is Route) { Route r = (Route)owner; foreach (SchemaFieldDefinition sdf in r.parent.emsxapi.routeFields) { Field f = new Field(this, sdf.name, ""); fields.Add(f); } } }
internal Fields(FieldsOwner owner) { this.owner = owner; loadFields(owner); }