Class CustomWrapperSchemaParameter
java.lang.Object
com.denodo.vdb.engine.customwrapper.CustomWrapperSchemaParameter
Defines a Custom Wrapper's schema parameter. Schema parameters have the
following characteristics:
- They can be simple or compound (in the latter case they will contain a
CustomWrapperSchemaParameter[]). - They can be of any of the types defined in
Types, includingjava.sql.Types.ARRAYandjava.sql.Types.STRUCT, in case they are compound. - They can be sortable, searchable, updateable, nullable and mandatory.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThis parameter supports both ascending and descending sort.static final intThis parameter supports ascending sort.static final intThis parameter supports descending sort.static final intThis parameter cannot be sorted. -
Constructor Summary
ConstructorsConstructorDescriptionCustomWrapperSchemaParameter(String name, int type) Creates a simple schema parameter with the following default properties: not mandatory searchable nullable updateable sortable (supports ascending and descending sort)getColumns()returnsnullCustomWrapperSchemaParameter(String name, int type, CustomWrapperSchemaParameter[] columns) Creates a complex schema parameter with the following default properties: not mandatory not searchable not updateable not sortable nullableCustomWrapperSchemaParameter(String name, int type, CustomWrapperSchemaParameter[] columns, boolean isSearchable, int sortableStatus, boolean isUpdateable, boolean isNullable, boolean isMandatory) Creates a schema parameter without any default property.CustomWrapperSchemaParameter(String name, int type, Integer typeSize, String typeName, Integer typeRadix, Integer typeDecimals, Map<String, String> extraProperties) Creates a simple schema parameter with the following default properties: not mandatory searchable nullable updateable sortable (supports ascending and descending sort)getColumns()returnsnullCustomWrapperSchemaParameter(String name, int type, Integer typeSize, String typeName, Integer typeRadix, Integer typeDecimals, Map<String, String> extraProperties, CustomWrapperSchemaParameter[] columns) Creates a complex schema parameter with the following default properties: not mandatory not searchable not updateable not sortable nullable propertiesCustomWrapperSchemaParameter(String name, int type, Integer typeSize, String typeName, Integer typeRadix, Integer typeDecimals, Map<String, String> extraProperties, CustomWrapperSchemaParameter[] columns, boolean isSearchable, int sortableStatus, boolean isUpdateable, boolean isNullable, boolean isMandatory) Creates a schema parameter without any default property. -
Method Summary
-
Field Details
-
NOT_SORTABLE
public static final int NOT_SORTABLEThis parameter cannot be sorted.- See Also:
-
ASCENDING_SORT
public static final int ASCENDING_SORTThis parameter supports ascending sort.- See Also:
-
DESCENDING_SORT
public static final int DESCENDING_SORTThis parameter supports descending sort.- See Also:
-
ASC_AND_DESC_SORT
public static final int ASC_AND_DESC_SORTThis parameter supports both ascending and descending sort.- See Also:
-
-
Constructor Details
-
CustomWrapperSchemaParameter
public CustomWrapperSchemaParameter(String name, int type, CustomWrapperSchemaParameter[] columns, boolean isSearchable, int sortableStatus, boolean isUpdateable, boolean isNullable, boolean isMandatory) Creates a schema parameter without any default property.- Parameters:
name- the name of this schema parametertype- one of the types defined injava.sql.Types.columns- an array of schema parameters, if this parameter is to be compound, ornullotherwise.isSearchable-trueif this parameter can be searched orfalseotherwise.sortableStatus- one ofNOT_SORTABLE,ASCENDING_SORT,DESCENDING_SORTorASC_AND_DESC_SORT.isUpdateable-trueif this parameter can be updated orfalseotherwise.isNullable-trueif this parameter can be made null orfalseotherwise.isMandatory-trueif this parameter is mandatory orfalseotherwise. This parameter will be ignored ifcolumnsis notnull.
-
CustomWrapperSchemaParameter
public CustomWrapperSchemaParameter(String name, int type, Integer typeSize, String typeName, Integer typeRadix, Integer typeDecimals, Map<String, String> extraProperties, CustomWrapperSchemaParameter[] columns, boolean isSearchable, int sortableStatus, boolean isUpdateable, boolean isNullable, boolean isMandatory) Creates a schema parameter without any default property.- Parameters:
name- the name of this schema parametertype- one of the types defined in the classTypesof the JDBC API.typeSize- its meaning depends on the type of the field:- For fields of type
text, it indicates the maximum length of the field. - For numeric types, the precision. Therefore, for
intandlongfields, this number is0.
- For fields of type
typeName- name of the type of the field in the source type properties of the field. E.g.VARCHAR,NCHAR,INTEGER,BIGINT, etc. These are the names of the constants defined in the classTypesof the JDBC API.typeRadix- number of fractional digits that a value of this field could store.typeDecimals- for fields of typedecimal, is the value of Type decimals of the source type properties of the field. Set this to0, for fields that are notdecimal.columns- an array of schema parameters, if this parameter is to be compound, ornullotherwise.isSearchable-trueif this parameter can be searched orfalseotherwise.sortableStatus- one ofNOT_SORTABLE,ASCENDING_SORT,DESCENDING_SORTorASC_AND_DESC_SORT.isUpdateable-trueif this parameter can be updated orfalseotherwise.isNullable-trueif this parameter can be made null orfalseotherwise.isMandatory-trueif this parameter is mandatory orfalseotherwise. This parameter will be ignored ifcolumnsis notnull.
-
CustomWrapperSchemaParameter
Creates a complex schema parameter with the following default properties:- not mandatory
- not searchable
- not updateable
- not sortable
- nullable
- Parameters:
name- this schema parameter's name.type- this schema parameter's type (one ofjava.sql.Types).columns- an array of schema parameters, representing this parameter's sub-parameters.
-
CustomWrapperSchemaParameter
public CustomWrapperSchemaParameter(String name, int type, Integer typeSize, String typeName, Integer typeRadix, Integer typeDecimals, Map<String, String> extraProperties, CustomWrapperSchemaParameter[] columns) Creates a complex schema parameter with the following default properties:- not mandatory
- not searchable
- not updateable
- not sortable
- nullable
- properties
- Parameters:
name- this schema parameter's name.type- this schema parameter's type (one ofjava.sql.Types).typeSize- its meaning depends on the type of the field:- For fields of type
text, it indicates the maximum length of the field. - For numeric types, the precision. Therefore, for
intandlongfields, this number is0.
- For fields of type
typeName- name of the type of the field in the source type properties of the field. E.g.VARCHAR,NCHAR,INTEGER,BIGINT, etc. These are the names of the constants defined in the classTypesof the JDBC API.typeRadix- number of fractional digits that a value of this field could store.typeDecimals- for fields of typedecimal, is the value of Type decimals of the source type properties of the field. Set this to0, for fields that are notdecimal.columns- an array of schema parameters, representing this parameter's sub-parameters.
-
CustomWrapperSchemaParameter
Creates a simple schema parameter with the following default properties:- not mandatory
- searchable
- nullable
- updateable
- sortable (supports ascending and descending sort)
getColumns()returnsnull
- Parameters:
name- this schema parameter's name.type- this schema parameter's type (one ofjava.sql.Types).
-
CustomWrapperSchemaParameter
public CustomWrapperSchemaParameter(String name, int type, Integer typeSize, String typeName, Integer typeRadix, Integer typeDecimals, Map<String, String> extraProperties) Creates a simple schema parameter with the following default properties:- not mandatory
- searchable
- nullable
- updateable
- sortable (supports ascending and descending sort)
getColumns()returnsnull
- Parameters:
name- this schema parameter's name.type- this schema parameter's type (one of constants defined in the classTypes).typeSize- its meaning depends on the type of the field:- For fields of type
text, it indicates the maximum length of the field. - For numeric types, the precision. Therefore, for
intandlongfields, this number is0.
- For fields of type
typeName- name of the type of the field in the source type properties of the field. E.g.VARCHAR,NCHAR,INTEGER,BIGINT, etc. These are the names of the constants defined in the classTypesof the JDBC API.typeRadix- number of fractional digits that a value of this field could store.typeDecimals- for fields of typedecimal, is the value of Type decimals of the source type properties of the field. Set this to0, for fields that are notdecimal.
-
-
Method Details
-
getName
- Returns:
- the name of this schema parameter
-
getType
public int getType()- Returns:
- one of the types defined in @{link Types}.
-
getTypeRadix
-
getTypeSize
-
getTypeName
-
getTypeDecimals
-
getColumns
- Returns:
- an array of schema parameters, if this parameter is compound.
-
isSearchable
public boolean isSearchable()- Returns:
trueif this parameter can be searched orfalseotherwise.
-
getSortableStatus
public int getSortableStatus()- Returns:
- one of
NOT_SORTABLE,ASCENDING_SORT,DESCENDING_SORTorASC_AND_DESC_SORT.
-
isUpdateable
public boolean isUpdateable()- Returns:
trueif this parameter can be updated orfalseotherwise.
-
isNullable
public boolean isNullable()- Returns:
trueif this parameter can be made null orfalseotherwise.
-
isMandatory
public boolean isMandatory()- Returns:
trueif this parameter is mandatory orfalseotherwise.
-
getParameterClass
Obtains the Java class of this schema parameter according to its type. The relation is as follows:java.sql.Types.ARRAY=Object[]java.sql.Types.BIGINT=Longjava.sql.Types.BINARY=Byte[]java.sql.Types.BIT=Booleanjava.sql.Types.BLOB=Byte[]java.sql.Types.BOOLEAN=Booleanjava.sql.Types.CHAR=Characterjava.sql.Types.CLOB=Character[]java.sql.Types.DATALINK=java.net.URLjava.sql.Types.DATE=java.sql.Datejava.sql.Types.DECIMAL=java.math.BigDecimaljava.sql.Types.DISTINCT=Objectjava.sql.Types.DOUBLE=Doublejava.sql.Types.FLOAT=Floatjava.sql.Types.INTEGER=Integerjava.sql.Types.JAVA_OBJECT=Objectjava.sql.Types.LONGVARBINARY=Byte[]java.sql.Types.LONGVARCHAR=Stringjava.sql.Types.NUMERIC=java.math.BigDecimaljava.sql.Types.REAL=Doublejava.sql.Types.SMALLINT=Integerjava.sql.Types.STRUCT=java.sql.Structjava.sql.Types.TIME=java.sql.Timejava.sql.Types.TIMESTAMP=java.sql.Timestampjava.sql.Types.TIMESTAMP_WITH_TIMEZONE=java.time.OffsetDateTimejava.sql.Types.TIME_WITH_TIMEZONE=java.time.OffsetTimejava.sql.Types.TIMESTAMP=java.sql.Timestampjava.sql.Types.TINYINT=Integerjava.sql.Types.VARBINARY=Byte[]java.sql.Types.VARCHAR=String
- Returns:
- the Java class of this schema parameter according to its type.
-
setExtraProperties
-
getExtraProperties
-
toString
-