toMatchFieldType method

MatchFieldType toMatchFieldType()

Implementation

MatchFieldType toMatchFieldType() {
  switch (this) {
    case 'URI':
      return MatchFieldType.uri;
    case 'QUERY_STRING':
      return MatchFieldType.queryString;
    case 'HEADER':
      return MatchFieldType.header;
    case 'METHOD':
      return MatchFieldType.method;
    case 'BODY':
      return MatchFieldType.body;
    case 'SINGLE_QUERY_ARG':
      return MatchFieldType.singleQueryArg;
    case 'ALL_QUERY_ARGS':
      return MatchFieldType.allQueryArgs;
  }
  throw Exception('$this is not known in enum MatchFieldType');
}