Example #1
0
 public static string GetText(this PepperlCmd val)
 {
     DescriptionAttribute[] attributes = (DescriptionAttribute[])val
                                         .GetType()
                                         .GetField(val.ToString())
                                         .GetCustomAttributes(typeof(DescriptionAttribute), false);
     return(attributes.Length > 0 ? attributes[0].Description : string.Empty);
 }
Example #2
0
 public Dictionary <String, String> SendCommand(PepperlCmd command, IEnumerable <String> parameters, IEnumerable <String> values)
 {
     return(SendCommand(command.GetText(), parameters, values));
 }
Example #3
0
 public Dictionary <String, String> SendCommand(PepperlCmd command, params String[] paramVals)
 {
     return(SendCommand(command.GetText(), paramVals));
 }
Example #4
0
 public Dictionary <String, String> SendCommand(PepperlCmd command)
 {
     return(JsonDumbParser.Parse(SendMessage(command.GetText())));
 }