Package uk.ac.starlink.table.jdbc
Class WriteMode
- java.lang.Object
-
- uk.ac.starlink.table.jdbc.WriteMode
-
public class WriteMode extends java.lang.Object
Defines how records are written to a database table.- Since:
- 11 Dec 2007
- Author:
- Mark Taylor
-
-
Field Summary
Fields Modifier and Type Field Description static WriteMode
APPEND
WriteMode which appends to an existing table.static WriteMode
CREATE
WriteMode which creates a new database table before writing.static WriteMode
DROP_CREATE
WriteMode which creates a new database table before writing.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static WriteMode[]
getAllModes()
Returns an array of all known write modes.java.lang.String
getDescription()
Returns a short description of this mode's operation.java.lang.String
toString()
Returns this mode's name.
-
-
-
Field Detail
-
CREATE
public static final WriteMode CREATE
WriteMode which creates a new database table before writing. It is an error if a table of the same name already exists.
-
DROP_CREATE
public static final WriteMode DROP_CREATE
WriteMode which creates a new database table before writing. If a table of the same name already exists, it is dropped first.
-
APPEND
public static final WriteMode APPEND
WriteMode which appends to an existing table. An error results if the named table has the wrong structure for the data being written.
-
-
Method Detail
-
getDescription
public java.lang.String getDescription()
Returns a short description of this mode's operation.- Returns:
- description
-
toString
public java.lang.String toString()
Returns this mode's name.- Overrides:
toString
in classjava.lang.Object
-
getAllModes
public static WriteMode[] getAllModes()
Returns an array of all known write modes.- Returns:
- write mode array
-
-