|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.vfny.geoserver.responses.wfs.WfsTransResponse
Java representation of a WFS_TransactionResponse xml element. The status and handle are required, so they are in the constructor, and a locator, a message, and any number of InsertResults can be added. This object can then write itself out to xml for a response.
Field Summary | |
static java.lang.String |
CUR_VERSION
Current version of wfs |
static short |
FAILED
Status if one of more operations failed |
static java.lang.String |
HANDLE
Name of the version element of the xml document |
static java.lang.String |
INSERT_RESULT
The name of the insert result element of the xml document |
static short |
PARTIAL
Status for transaction partially succeeding, data in incosistent state. |
static java.lang.String |
ROOT
The name of the root element of the xml document |
short |
status
Status of the transaction represented by this response. |
static java.lang.String |
STATUS
Name of the status element of the xml document |
static short |
SUCCESS
Status if the transaction was successful |
static java.lang.String |
TRANS_RESULT
Name of the transaction result element of the xml document |
static java.lang.String |
V_OFFSET
|
static java.lang.String |
VERSION
Name of the version element of the xml document |
Constructor Summary | |
WfsTransResponse(short status,
boolean verbose)
Only constructor, as status is mandatory |
|
WfsTransResponse(short status,
java.lang.String handle,
boolean verbose)
Convenience constructor, for status and handle |
Method Summary | |
void |
addInsertResult(java.lang.String handle,
java.util.Collection featureIds)
adds an insert result for a successful insert operation. |
java.lang.String |
getXmlResponse(Request gs)
|
void |
setHandle(java.lang.String handle)
Sets the handle for this response. |
void |
setLocator(java.lang.String locator)
Sets the string to indicate which part of the transaction failed. |
void |
setMessage(java.lang.String message)
Sets the string to give a message about a failure. |
void |
writeXmlResponse(java.io.Writer writer,
Request request)
Generates the xml represented by this object. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final short SUCCESS
public static final short FAILED
public static final short PARTIAL
public static final java.lang.String ROOT
public static final java.lang.String INSERT_RESULT
public static final java.lang.String TRANS_RESULT
public static final java.lang.String VERSION
public static final java.lang.String CUR_VERSION
public static final java.lang.String HANDLE
public static final java.lang.String STATUS
public static final java.lang.String V_OFFSET
public final short status
Constructor Detail |
public WfsTransResponse(short status, boolean verbose)
status
- The status of the transaction.verbose
- DOCUMENT ME!public WfsTransResponse(short status, java.lang.String handle, boolean verbose)
status
- The status of the transaction.handle
- the handle of the response. Should be the same as the
handle of the transaction request.verbose
- DOCUMENT ME!Method Detail |
public void setHandle(java.lang.String handle)
handle
- the handle of the response. Should be the same as the
handle of the transaction request.public void setLocator(java.lang.String locator)
locator
- the handle of the failed transaction.public void setMessage(java.lang.String message)
message
- to give the user information about the failure.public void addInsertResult(java.lang.String handle, java.util.Collection featureIds)
handle
- the handle of the insert request.featureIds
- the collection of successfully added feature ids.public void writeXmlResponse(java.io.Writer writer, Request request) throws java.io.IOException
writer
- DOCUMENT ME!request
- DOCUMENT ME!
java.io.IOException
- DOCUMENT ME!public java.lang.String getXmlResponse(Request gs)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |