public static Guid GetGuid(this switch_event e) { return(e.GetHeader("Unique-ID") == null ? Guid.Empty : Guid.Parse(e.GetHeader("Unique-ID").value)); }
public static String GetValueOfHeader(this switch_event e, String headerName, String defaultValue = "") { var head = e.GetHeader(headerName); return(head == null ? defaultValue : head.value); }