|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgov.noaa.edsd.sessionlessRemoteXmlDb.SessionlessXmldbService
Provides a really simple interface to an XAPI database.
| Field Summary | |
static java.lang.String |
DATABASE_KEY
|
| Constructor Summary | |
SessionlessXmldbService()
Creates a new instance of Service |
|
| Method Summary | |
void |
destroy()
removes reference to database |
java.lang.String |
getXmlResource(java.lang.String collectionName,
java.lang.String resourceId,
java.lang.String userName,
java.lang.String password)
Retrieves a resource by id |
java.lang.String |
getXmlResourceWithXpath(java.lang.String collectionName,
java.lang.String xpathQuery,
java.lang.String userName,
java.lang.String password)
Retrieves a resource using xpath |
void |
init(java.lang.Object context)
Grabs the Database from the servlet context with attribute "org.xmldb.api.base.Database". |
java.lang.String |
insertResource(java.lang.String collectionName,
java.lang.String xml,
java.lang.String userName,
java.lang.String password)
Saves the specified XML String in the collection. |
boolean |
isCollectionAvailable(java.lang.String collectionName)
Checks to see if the collection is available |
void |
updateResource(java.lang.String collectionName,
java.lang.String resourceId,
java.lang.String xml,
java.lang.String userName,
java.lang.String password)
Updates the specified resource by replaceing the entire record with the specified record. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static java.lang.String DATABASE_KEY
| Constructor Detail |
public SessionlessXmldbService()
| Method Detail |
public void init(java.lang.Object context)
throws javax.xml.rpc.ServiceException
init in interface javax.xml.rpc.server.ServiceLifecyclecontext - The ServletEndpiontContext
javax.xml.rpc.ServiceExceptionpublic void destroy()
destroy in interface javax.xml.rpc.server.ServiceLifecycle
public boolean isCollectionAvailable(java.lang.String collectionName)
throws SessionlessException
collectionName -
SessionlessException
public java.lang.String getXmlResourceWithXpath(java.lang.String collectionName,
java.lang.String xpathQuery,
java.lang.String userName,
java.lang.String password)
throws SessionlessException
collectionName - The name of the collection to userxpathQuery - The xpath to use to find a resourceuserName - The user name used for verificationpassword - The password used for verification
SessionlessException
public java.lang.String getXmlResource(java.lang.String collectionName,
java.lang.String resourceId,
java.lang.String userName,
java.lang.String password)
throws SessionlessException
collectionName - The name of the collectionresourceId - The id of the resource to retrieve
SessionlessException
public void updateResource(java.lang.String collectionName,
java.lang.String resourceId,
java.lang.String xml,
java.lang.String userName,
java.lang.String password)
throws SessionlessException
collectionName - The collection which contains the current resourceresourceId - The id of the resourcexml - The xml string to replaceuserName - The user name to use for verificationpassword - The password to use for verification
SessionlessException
public java.lang.String insertResource(java.lang.String collectionName,
java.lang.String xml,
java.lang.String userName,
java.lang.String password)
throws SessionlessException
collectionName - The name of the collection to insert the record in.xml - The xml to insert.userName - The user name to use for verificationpassword - The password to use for verification
SessionlessException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||