public class StandardHubProfileFactory extends java.lang.Object implements HubProfileFactory
Modifier and Type | Field and Description |
---|---|
private static java.lang.String |
lockUsage_ |
private static java.lang.String |
secretUsage_ |
Constructor and Description |
---|
StandardHubProfileFactory() |
Modifier and Type | Method and Description |
---|---|
HubProfile |
createHubProfile(java.util.List flagList)
Creates a HubProfile perhaps configured using a supplied list
of flags.
|
java.lang.String[] |
getFlagsUsage()
Returns an array of strings, each describing one command-line flag
which will be consumed by the
createProfile method. |
java.lang.Class |
getHubProfileClass()
Returns a HubProfile subclass with a no-arg constructor which,
when invoked, will produce a basic instance of the HubProfile
represented by this factory.
|
java.lang.String |
getName()
Returns "std".
|
private static final java.lang.String secretUsage_
private static final java.lang.String lockUsage_
public java.lang.String getName()
getName
in interface HubProfileFactory
public java.lang.String[] getFlagsUsage()
HubProfileFactory
createProfile
method.getFlagsUsage
in interface HubProfileFactory
public HubProfile createHubProfile(java.util.List flagList) throws java.io.IOException
HubProfileFactory
HubProfileFactory.getFlagsUsage()
command are used for configuration of the
returned hub, and must be removed from the flagList
list.
Unrecognised flags should be ignored and left in the list.
Flags which are recognised but badly formed should raise a
RuntimeException with a helpful message.createHubProfile
in interface HubProfileFactory
flagList
- mutable list of Strings giving command-ilne flags,
some of which may be intended for configuring a profilejava.io.IOException
public java.lang.Class getHubProfileClass()
HubProfileFactory
HubProfileFactory.createHubProfile(java.util.List)
with an empty flag list.getHubProfileClass
in interface HubProfileFactory