Package org.apache.subversion.javahl
Interface ISVNConfig.Category
- Enclosing interface:
- ISVNConfig
public static interface ISVNConfig.Category
Interface for reading and modifying configuration
categories. Returned by
ISVNConfig.config()
and
ISVNConfig.servers()
.-
Method Summary
Modifier and Type Method Description void
enumerate(String section, ISVNConfig.Enumerator handler)
Callhandler
once for each option in the configuration category.boolean
get(String section, String option, boolean defaultValue)
Returns the boolean value of a configuration option.long
get(String section, String option, long defaultValue)
Returns the long integer value of a configuration option.String
get(String section, String option, String defaultValue)
Returns the value of a configuration option.Tristate
get(String section, String option, String unknown, Tristate defaultValue)
Returns theTristate
value of a configuration option.String
getYesNoAsk(String section, String option, String defaultValue)
Check that the configuration option's value is true, false or "ask".Iterable<String>
sections()
void
set(String section, String option, boolean value)
Set the value of a configuration option to represent a boolean.void
set(String section, String option, long value)
Set the value of a configuration option to represent a long integer.void
set(String section, String option, String value)
Set the value of a configuration option.
-
Method Details
-
get
Returns the value of a configuration option.- Parameters:
section
- The section nameoption
- The option namedefaultValue
- Return this if the option was not found.
-
get
Returns the boolean value of a configuration option. The recognized representations are 'true'/'false', 'yes'/'no', 'on'/'off', '1'/'0'; case does not matter.- Throws:
ClientException
- if the value cannot be parsed.- See Also:
get(String,String,String)
-
get
Returns the long integer value of a configuration option.- Throws:
ClientException
- See Also:
get(String,String,boolean)
-
get
Tristate get(String section, String option, String unknown, Tristate defaultValue) throws ClientExceptionReturns theTristate
value of a configuration option.- Parameters:
unknown
- The value used forTristate.Unknown
.- Throws:
ClientException
- See Also:
get(String,String,boolean)
-
getYesNoAsk
Check that the configuration option's value is true, false or "ask". The boolean representations are the same as those understood byget(String,String,boolean)
. If the option is not found, the default value will be parsed instead.- Returns:
ISVNConfig.TRUE
,ISVNConfig.FALSE
orISVNConfig.ASK
- Throws:
ClientException
- if the either the value or the default cannot be parsed.
-
set
Set the value of a configuration option.- Parameters:
section
- The section nameoption
- The option namevalue
- The value to set the option to; passingnull
will delete the option.
-
set
Set the value of a configuration option to represent a boolean.- See Also:
set(String,String,String)
-
set
Set the value of a configuration option to represent a long integer.- See Also:
set(String,String,String)
-
sections
- Returns:
- the names of all the sections in the configuration category.
-
enumerate
Callhandler
once for each option in the configuration category.
-