public class SyntaxRepository extends Object
Constructor and Description |
---|
SyntaxRepository()
Create a syntax repository using all syntaxes found ...
|
Modifier and Type | Method and Description |
---|---|
void |
addSyntaxDefinitions(InputStream is)
Parses the command-line syntax definitions supplied through the given
input stream and adds the resulting syntax package to the repository.
|
SyntaxCompiler |
compiler()
Get the syntax compiler utility instance
|
SyntaxMatch |
match(String[] args)
Matches an array of string arguments that were present on the CLIF
client's arguments list, and attempts to match them against a defined
syntax.
|
Set<SyntaxPackage> |
packages()
Gets the set of all discovered syntax packages.
|
SyntaxUsage |
syntaxUsage()
Get the syntax usage utility instance
|
public SyntaxRepository()
public Set<SyntaxPackage> packages()
public void addSyntaxDefinitions(InputStream is) throws IOException
is
- input stream containing the XML definition of command-line
syntaxIOException
- if issues are encountered reading from the given
input streampublic SyntaxMatch match(String[] args) throws BadUsageException
args
- arguments that have been pulled from a the CLIF client's
execution of a command line commandBadUsageException
- if the given arguments do not match with any
defined syntaxpublic SyntaxUsage syntaxUsage()
SyntaxUsage
utilitypublic SyntaxCompiler compiler()
Copyright © 2015. All Rights Reserved.