Class DbSchema
java.lang.Object
com.perforce.p4java.impl.generic.admin.DbSchema
- All Implemented Interfaces:
IDbSchema
Simple default implementation class for the IDbSchema interface.
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()intvoidsetColumnMetadata(List<Map<String, String>> columnMetadata) Set the colum metadata map.voidSet the name of the table.voidsetVersion(int version) Set the table schema version.
-
Constructor Details
-
DbSchema
public DbSchema()Default constructor. -
DbSchema
Construct a DbSchema using explicit field values.- Parameters:
name- nameversion- versioncolumnMetadata- columnMetadata
-
DbSchema
Construct a DbSchema from a map returned by the Perforce server.Don't use this unless you know the correct format of the maps and you either got the map directly from the server or you cobbled together something suitable yourself. No real error- or sanity-checking is done here.
- Parameters:
map- map data
-
-
Method Details
-
getColumnMetadata
- Specified by:
getColumnMetadatain interfaceIDbSchema- Returns:
- a list of column metadata maps. Note that while this list should never be null, individual map values within it may be null. Field (map key) names and values are not explained here.
- See Also:
-
getName
-
getVersion
public int getVersion()- Specified by:
getVersionin interfaceIDbSchema- Returns:
- the table schema version.
- See Also:
-
setName
Description copied from interface:IDbSchemaSet the name of the table. -
setVersion
public void setVersion(int version) Description copied from interface:IDbSchemaSet the table schema version.- Specified by:
setVersionin interfaceIDbSchema- Parameters:
version- schema version
-
setColumnMetadata
Description copied from interface:IDbSchemaSet the colum metadata map.- Specified by:
setColumnMetadatain interfaceIDbSchema- Parameters:
columnMetadata- data
-