public class AttributesManager
extends java.lang.Object
Constructor and Description |
---|
AttributesManager() |
Modifier and Type | Method and Description |
---|---|
XMLDBAttribute |
createAttribute(XMLDBAttribute attribute)
Save a new user defined attribute into the database.
|
void |
deleteAttribute(XMLDBAttribute attribute)
Delete an existing attribute from the database.
|
java.util.List<XMLDBAttribute> |
getDBAttributes()
Call to the database and retrieve the list attributes stored there.
|
void |
updateAttribute(XMLDBAttribute attribute)
Update an existing attribute in the database with the new information.
|
public XMLDBAttribute createAttribute(XMLDBAttribute attribute) throws DBConnectionException, DBExecutionException
attribute
- The attribute to be saved in the database. It
contains the information to be stored for that attribute.DBConnectionException
- Thrown from the database layer if the
database layer fails to create a connection to the database.DBExecutionException
- Thrown from the database layer if the
database layer fails to execute the operations in the database.public void deleteAttribute(XMLDBAttribute attribute) throws DBConnectionException, DBExecutionException
attribute
- The attribute to be deleted from the database.DBConnectionException
- Thrown from the database layer if the
database layer fails to create a connection to the database.DBExecutionException
- Thrown from the database layer if the
database layer fails to execute the operations in the database.public java.util.List<XMLDBAttribute> getDBAttributes() throws DBExecutionException, DBConnectionException
DBExecutionException
- Thrown if the operation fails.DBConnectionException
- Thrown if the db layer fails to create
the connection.public void updateAttribute(XMLDBAttribute attribute) throws DBConnectionException, DBExecutionException
attribute
- The attribute to be updated in the database. It
contains the new information to be stored for that attribute.DBConnectionException
- Thrown from the database layer if the
database layer fails to create a connection to the database.DBExecutionException
- Thrown from the database layer if the
database layer fails to execute the operations in the database.