Interface BaseProperties
- 
- All Known Subinterfaces:
- AttachmentProperties,- BackupManager,- DatabaseConnectionProperties,- EventManager,- FBManagerMBean,- FirebirdConnectionProperties,- IAttachProperties<T>,- IConnectionProperties,- IServiceProperties,- MaintenanceManager,- NBackupManager,- ServiceConnectionProperties,- ServiceManager,- StatisticsManager,- TraceManager,- UserManager
 - All Known Implementing Classes:
- AbstractAttachProperties,- AbstractConnectionPropertiesDataSource,- AbstractImmutableAttachProperties,- FBAbstractCommonDataSource,- FBBackupManager,- FBBackupManagerBase,- FBConnectionPoolDataSource,- FbConnectionProperties,- FBConnectionProperties,- FBEventManager,- FbImmutableConnectionProperties,- FbImmutableServiceProperties,- FBMaintenanceManager,- FBManagedConnectionFactory,- FBManager,- FBNBackupManager,- FBServiceManager,- FbServiceProperties,- FBSimpleDataSource,- FBStatisticsManager,- FBStreamingBackupManager,- FBTraceManager,- FBUserManager,- FBXADataSource
 
 public interface BasePropertiesBase of the properties hierarchy; provides common API for setting properties by name.- Since:
- 5
- Author:
- Mark Rotteveel
 
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description java.util.Map<ConnectionProperty,java.lang.Object>connectionPropertyValues()An unmodifiable view on the connection properties held by this BaseProperties implementation.java.lang.BooleangetBooleanProperty(java.lang.String name)Retrieves abooleanproperty value by name.default booleangetBooleanProperty(java.lang.String name, boolean defaultIfNull)Retrieves abooleanproperty value by name, with a default if it'snull.java.lang.IntegergetIntProperty(java.lang.String name)Retrieves anintproperty value by name.default intgetIntProperty(java.lang.String name, int defaultIfNull)Retrieves anintproperty value by name, with a default if it'snull.java.lang.StringgetProperty(java.lang.String name)Retrieves a string property value by name.default java.lang.StringgetProperty(java.lang.String name, java.lang.String defaultIfNull)Retrieves a string property value by name, with a default if it'snull.voidsetBooleanProperty(java.lang.String name, java.lang.Boolean value)Sets abooleanproperty by name.voidsetIntProperty(java.lang.String name, java.lang.Integer value)Sets anintproperty by name.voidsetProperty(java.lang.String name, java.lang.String value)Sets a property by name.
 
- 
- 
- 
Method Detail- 
getPropertyjava.lang.String getProperty(java.lang.String name) Retrieves a string property value by name.For properties with an explicit default, this method should return the string presentation of that default, not null. Forintorbooleanthe string equivalent is returned.- Parameters:
- name- Property name (not- nullor empty)
- Returns:
- Value of the property, or nullwhen not set or not a known property
 
 - 
getPropertydefault java.lang.String getProperty(java.lang.String name, java.lang.String defaultIfNull)Retrieves a string property value by name, with a default if it'snull.- Parameters:
- name- Property name (not- nullor empty)
- Returns:
- Value of the property, or defaultIfNullwhen not set or not a known property
 
 - 
setPropertyvoid setProperty(java.lang.String name, java.lang.String value)Sets a property by name.This method can be used to set all defined properties, but also properties not known by Jaybird. When setting intorbooleanproperties, the appropriate conversions are applied. Usingnullwill reset to the default value. Forbooleanproperties, an empty string is taken to meantrue.- Parameters:
- name- Property name (not- nullor empty)
- value- Property value (use- nullto apply default)
- Throws:
- java.lang.IllegalArgumentException- When the specified property is an- intor- booleanproperty and the value is not- nulland not a valid- intor- boolean
 
 - 
getIntPropertyjava.lang.Integer getIntProperty(java.lang.String name) Retrieves anintproperty value by name.For properties with an explicit default, this method should return the integer presentation of that default. For implementation simplicity, it is allowed to convert any string property to intinstead of checking if something is actually anintproperty- Parameters:
- name- Property name (not- nullor empty)
- Returns:
- Integer with value of the property, or nullwhen not set
- Throws:
- java.lang.NumberFormatException- If the property is not an- int propertyand the value cannot be converted to an integer
- java.lang.IllegalArgumentException- (optional) If the specified property is not an- intproperty
 
 - 
getIntPropertydefault int getIntProperty(java.lang.String name, int defaultIfNull)Retrieves anintproperty value by name, with a default if it'snull.- Parameters:
- name- Property name (not- nullor empty)
- defaultIfNull- Default value when- null
- Returns:
- The value or defaultIfNullwhen the value isnull
- See Also:
- getIntProperty(String)
 
 - 
setIntPropertyvoid setIntProperty(java.lang.String name, java.lang.Integer value)Sets anintproperty by name.For implementation simplicity, it is allowed to also set string properties. The value set will be the string equivalent. - Parameters:
- name- Property name (not- nullor empty)
- value- Property value (use- nullto apply default)
- Throws:
- java.lang.IllegalArgumentException- If the specified property is a- booleanproperty
 
 - 
getBooleanPropertyjava.lang.Boolean getBooleanProperty(java.lang.String name) Retrieves abooleanproperty value by name.For properties with an explicit default, this method should return the boolean presentation of that default. For implementation simplicity, it is allowed to convert any string property to booleaninstead of checking if something is actually anintproperty- Parameters:
- name- Property name (not- nullor empty)
- Returns:
- Integer with value of the property, or nullwhen not set
- Throws:
- java.lang.IllegalArgumentException- If the property value is not- nulland cannot be converted to a boolean (- trueor empty string,- false), (optional) if the specified property is not a- booleanproperty
 
 - 
getBooleanPropertydefault boolean getBooleanProperty(java.lang.String name, boolean defaultIfNull)Retrieves abooleanproperty value by name, with a default if it'snull.- Parameters:
- name- Property name (not- nullor empty)
- defaultIfNull- Default value when- null
- Returns:
- The value or defaultIfNullwhen the value isnull
- See Also:
- getBooleanProperty(String)
 
 - 
setBooleanPropertyvoid setBooleanProperty(java.lang.String name, java.lang.Boolean value)Sets abooleanproperty by name.For implementation simplicity, it is allowed to also set string properties. The value set will be the string equivalent. - Parameters:
- name- Property name (not- nullor empty)
- value- Property value (use- nullto apply default)
- Throws:
- java.lang.IllegalArgumentException- If the specified property is an- intproperty
 
 - 
connectionPropertyValuesjava.util.Map<ConnectionProperty,java.lang.Object> connectionPropertyValues() An unmodifiable view on the connection properties held by this BaseProperties implementation.Be aware, implementations can have additional properties that are not mapped from ConnectionProperty. Such properties will need to be retrieved in an implementation-specific manner.- Returns:
- An unmodifiable view on the property values held in this properties instance
 
 
- 
 
-