Package com.ocient.cli.extract

# Class ExtractSyntaxParser

java.lang.Object
com.ocient.cli.extract.ExtractSyntaxParser

    public class ExtractSyntaxParser
    extends Object

A utility class for parsing the "EXTRACT TO" syntax into its configuration and query components

## Nested Class Summary

Nested Classes
Modifier and Type | Class | Description
--- | --- | ---
`static class` | `ExtractSyntaxParser.ParseResult` | A class to wrap the result of an "EXTRACT TO" parse

## Field Summary

Fields
Modifier and Type | Field | Description
--- | --- | ---
`static Pattern` | `ARG_VAL_PATTERN` |

## Constructor Summary

Constructors
Constructor | Description
--- | ---
`ExtractSyntaxParser()` |

## Method Summary

Modifier and Type | Method | Description
--- | --- | ---
`static ExtractSyntaxParser.ParseResult` | `parse​(String cmd)` | Parse an "EXTRACT TO" command
`static List<String>` | `stringTokenizer​(String options)` | Seperates key and value(possible quoted) pairs into sets Ex: key1=val1,key2="val2",key3=val3 === [key1=val1, key2=val2, key3=val3]

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### ARG_VAL_PATTERN

public static final Pattern ARG_VAL_PATTERN

## Constructor Details

### ExtractSyntaxParser

public ExtractSyntaxParser()

## Method Details

### parse

public static ExtractSyntaxParser.ParseResult parse​(String cmd)
Parse an "EXTRACT TO" command

Parameters:
  `cmd` - the command string
Returns:
  the ParseResult from the command string
Throws:
  `ParseException` - if the command could not be parsed

### stringTokenizer

public static List<String> stringTokenizer​(String options) throws ParseException
Seperates key and value(possible quoted) pairs into sets Ex: key1=val1,key2="val2",key3=val3 === [key1=val1, key2=val2, key3=val3]

Parameters:
  `options` - option string containing all the options.
Returns:
  List seperated key=value pairs.
Throws:
  `ParseException`