Package org.apache.subversion.javahl
Interface ISVNConfig.Category
-
- Enclosing interface:
- ISVNConfig
public static interface ISVNConfig.CategoryInterface for reading and modifying configuration categories. Returned byISVNConfig.config()andISVNConfig.servers().
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidenumerate(String section, ISVNConfig.Enumerator handler)Callhandleronce for each option in the configuration category.booleanget(String section, String option, boolean defaultValue)Returns the boolean value of a configuration option.longget(String section, String option, long defaultValue)Returns the long integer value of a configuration option.Stringget(String section, String option, String defaultValue)Returns the value of a configuration option.Tristateget(String section, String option, String unknown, Tristate defaultValue)Returns theTristatevalue of a configuration option.StringgetYesNoAsk(String section, String option, String defaultValue)Check that the configuration option's value is true, false or "ask".Iterable<String>sections()voidset(String section, String option, boolean value)Set the value of a configuration option to represent a boolean.voidset(String section, String option, long value)Set the value of a configuration option to represent a long integer.voidset(String section, String option, String value)Set the value of a configuration option.
-
-
-
Method Detail
-
get
String get(String section, String option, String defaultValue)
Returns the value of a configuration option.- Parameters:
section- The section nameoption- The option namedefaultValue- Return this if the option was not found.
-
get
boolean get(String section, String option, boolean defaultValue) throws ClientException
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
long get(String section, String option, long defaultValue) throws ClientException
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 ClientException
Returns theTristatevalue of a configuration option.- Parameters:
unknown- The value used forTristate.Unknown.- Throws:
ClientException- See Also:
get(String,String,boolean)
-
getYesNoAsk
String getYesNoAsk(String section, String option, String defaultValue) throws ClientException
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.FALSEorISVNConfig.ASK- Throws:
ClientException- if the either the value or the default cannot be parsed.
-
set
void set(String section, String option, String value)
Set the value of a configuration option.- Parameters:
section- The section nameoption- The option namevalue- The value to set the option to; passingnullwill delete the option.
-
set
void set(String section, String option, boolean value)
Set the value of a configuration option to represent a boolean.- See Also:
set(String,String,String)
-
set
void set(String section, String option, long value)
Set the value of a configuration option to represent a long integer.- See Also:
set(String,String,String)
-
sections
Iterable<String> sections()
- Returns:
- the names of all the sections in the configuration category.
-
enumerate
void enumerate(String section, ISVNConfig.Enumerator handler)
Callhandleronce for each option in the configuration category.
-
-