public GruntTaskOption FromYaml(string yaml) { IDeserializer deserializer = new DeserializerBuilder().Build(); SerializedGruntTaskOption option = deserializer.Deserialize <SerializedGruntTaskOption>(yaml); return(this.FromSerializedGruntTaskOption(option)); }
internal GruntTaskOption FromSerializedGruntTaskOption(SerializedGruntTaskOption option) { this.Name = option.Name; this.Value = option.Value; this.DefaultValue = option.DefaultValue; this.Description = option.Description; this.SuggestedValues = option.SuggestedValues; this.Optional = option.Optional; this.DisplayInCommand = option.DisplayInCommand; this.FileOption = option.FileOption; return(this); }
public GruntTaskOption FromJson(string json) { SerializedGruntTaskOption option = JsonConvert.DeserializeObject <SerializedGruntTaskOption>(json); return(this.FromSerializedGruntTaskOption(option)); }