An implementation of a JMManager for a Tamino database.
getDeleteQuery
protected String getDeleteQuery(Element pElement)
throws JAXBException,
InvocationTargetException,
IllegalAccessException,
NoSuchMethodException,
UnsupportedEncodingException
Returns a query suited for deleting the element.
getElementTag
public String getElementTag()
Returns the qualified element name of the root element.
This is used in delete or select queries for creation
of an XPath query.
getIdTag
public String getIdTag()
Returns the qualified attribute name of the ID attribute.
This is used in delete or update queries for creation
of an XQL statement.
getInsertQuery
protected String getInsertQuery(Element pElement)
throws JAXBException,
UnsupportedEncodingException
Returns a query suited for inserting the element.
getPassword
protected String getPassword()
getResponse
protected java.net.HttpURLConnection getResponse(String pQuery)
throws SAXException
Performs a single database query.
getUpdateQuery
protected String getUpdateQuery(Element pElement)
throws JAXBException,
UnsupportedEncodingException
Returns a query suited for updating the element.
getUser
protected String getUser()
performQuery
protected InoResponseHandler performQuery(String pQuery,
java.util.List pList)
throws SAXException
Performs a single database query.
performQuery
protected void performQuery(String pQuery,
InoResponseHandler pHandler)
throws SAXException
Parses a single INO response document.
select
public void select(Observer pObserver,
String pQuery,
PMParams pPlaceHolderArgs)
throws JAXBException
Reads documents matching the given query. For any document
matching, the Observer's notify method is executed with the
matching document as an argument.
The query may contain placeholders. If it does, you have
to supply an instance of
PMParams
with the placeholder
values. Example:
manager.select("Name = ? and Id = ?",
new PMParams().addString("Someone").addInt(4));
- select in interface PM
pObserver
- This Observer is notified for any matching document.
The document is added as an argument.pQuery
- The query to perform. May contain placeholders.pPlaceHolderArgs
- An array of objects or null, if the
query doesn't contain any placeholders.
setElementTag
public void setElementTag(String pElementTag)
Sets the qualified element name of the root element.
This is used in delete or select queries for creation
of an XQL statement.
setIdTag
public void setIdTag(String pIdTag)
Returns the qualified attribute name of the ID attribute.
This is used in delete or update queries for creation
of an XQL statement.