@Override public String getYesNoAsk(String section, String option, String defaultValue) throws ClientException { final String propertyValue = configFile.getPropertyValue(section, option); return propertyValue == null ? defaultValue : propertyValue; }
@Override public String get(String section, String option, String defaultValue) { final String propertyValue = configFile.getPropertyValue(section, option); return propertyValue == null ? defaultValue : propertyValue; }
@Override public long get(String section, String option, long defaultValue) throws ClientException { final String propertyValue = configFile.getPropertyValue(section, option); try { return propertyValue == null ? defaultValue : Long.parseLong(propertyValue); } catch (NumberFormatException e) { return defaultValue; } }
@Override public boolean get(String section, String option, boolean defaultValue) throws ClientException { final String propertyValue = configFile.getPropertyValue(section, option); return propertyValue == null ? defaultValue : TRUE_VALUES.contains(propertyValue.toLowerCase()); }
@Override public Tristate get(String section, String option, String unknown, Tristate defaultValue) throws ClientException { final String propertyValue = configFile.getPropertyValue(section, option); if (propertyValue == null) { return defaultValue; } else if (TRUE_VALUES.contains(propertyValue.toLowerCase())) { return Tristate.True; } else if (FALSE_VALUES.contains(propertyValue.toLowerCase())) { return Tristate.False; } else { return Tristate.Unknown; } }
public String getDiffCommand() { return getConfigFile().getPropertyValue(HELPERS_GROUP, DIFF_CMD); }
public String getMergeTool() { return getConfigFile().getPropertyValue(HELPERS_GROUP, MERGE_TOOL_CMD); }
public String[] getPasswordStorageTypes() { String storeTypesOption = getConfigFile().getPropertyValue("auth", "password-stores"); if (storeTypesOption == null) { return DEFAULT_PASSWORD_STORE_TYPES; } List storeTypes = new ArrayList(); for (StringTokenizer types = new StringTokenizer(storeTypesOption, " ,"); types.hasMoreTokens();) { String type = types.nextToken(); type = type == null ? null : type.trim(); if (type != null && !"".equals(type)) { storeTypes.add(type); } } return (String[]) storeTypes.toArray(new String[storeTypes.size()]); }
public String getLogEncoding() { return getConfigFile().getPropertyValue(MISCELLANY_GROUP, LOG_ENCODING); }
public String getMergeTool() { return getConfigFile().getPropertyValue(HELPERS_GROUP, MERGE_TOOL_CMD); }
protected boolean isStorePasswords(SVNURL url) { boolean store = true; String value = getConfigFile().getPropertyValue("auth", "store-passwords"); if (value != null) { store = "yes".equalsIgnoreCase(value) || "on".equalsIgnoreCase(value) || "true".equalsIgnoreCase(value); } String host = url != null ? url.getHost() : null; Map properties = getHostProperties(host); String storePasswords = (String) properties.get("store-passwords"); if (storePasswords == null) { return store; } return "yes".equalsIgnoreCase(storePasswords) || "on".equalsIgnoreCase(storePasswords) || "true".equalsIgnoreCase(storePasswords); }
public boolean isKeepLocks() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, NO_UNLOCK); return getBooleanValue(value, false); }
public boolean isKeepLocks() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, NO_UNLOCK); return getBooleanValue(value, false); }
public boolean isUseCommitTimes() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, USE_COMMIT_TIMES); return getBooleanValue(value, false); }
public boolean isUseCommitTimes() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, USE_COMMIT_TIMES); return getBooleanValue(value, false); }
public boolean isInteractiveConflictResolution() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, INTERACTIVE_COFLICTS); return getBooleanValue(value, true); }
public boolean isUseCommitTimes() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, USE_COMMIT_TIMES); return getBooleanValue(value, false); }
public boolean isKeepLocks() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, NO_UNLOCK); return getBooleanValue(value, false); }
public boolean isInteractiveConflictResolution() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, INTERACTIVE_COFLICTS); return getBooleanValue(value, true); }
public boolean isInteractiveConflictResolution() { String value = getConfigFile().getPropertyValue(MISCELLANY_GROUP, INTERACTIVE_COFLICTS); return getBooleanValue(value, true); }