public object?GetNthMask(int index) { MapMarker_FieldIndex enu = (MapMarker_FieldIndex)index; switch (enu) { case MapMarker_FieldIndex.Flags: return(Flags); case MapMarker_FieldIndex.Name: return(Name); case MapMarker_FieldIndex.Type: return(Type); default: throw new ArgumentException($"Index is out of range: {index}"); } }
public void SetNthMask(int index, object obj) { MapMarker_FieldIndex enu = (MapMarker_FieldIndex)index; switch (enu) { case MapMarker_FieldIndex.Flags: this.Flags = (Exception?)obj; break; case MapMarker_FieldIndex.Name: this.Name = (Exception?)obj; break; case MapMarker_FieldIndex.Type: this.Type = (Exception?)obj; break; default: throw new ArgumentException($"Index is out of range: {index}"); } }