|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.google.gdata.data.batch.BatchUtils
public class BatchUtils
Utility methods for setting up and using batch feeds and entries.
Constructor Summary | |
---|---|
BatchUtils()
|
Method Summary | |
---|---|
static void |
declareEntryExtensions(ExtensionProfile extProfile)
Declares only the entry extensions in an extension profile. |
static void |
declareExtensions(ExtensionProfile extProfile)
Declares batch feed and entry extensions as well as the batch namespace in an extension profile. |
static void |
declareFeedExtensions(ExtensionProfile extProfile)
Declares only the feed extensions in an extension profile. |
static java.lang.String |
getBatchId(BaseEntry<?> entry)
Gets the value of the tag <batch:id> . |
static BatchInterrupted |
getBatchInterrupted(ExtensionPoint extPoint)
Gets the value of the tag <batch:interrupted> . |
static BatchOperationType |
getBatchOperationType(ExtensionPoint extPoint)
Gets the batch operation type from the tag <batch:operation>
in a ExtensionPoint . |
static BatchStatus |
getBatchStatus(ExtensionPoint extPoint)
Gets the value of the tag <batch:status> . |
static boolean |
isFailure(ExtensionPoint extPoint)
Checks whether a batch entry is an error report. |
static boolean |
isSuccess(ExtensionPoint extPoint)
Checks whether a batch entry is a success report. |
static void |
setBatchId(ExtensionPoint extPoint,
java.lang.String id)
Sets the value of the tag <batch:id> . |
static void |
setBatchOperationType(ExtensionPoint extPoint,
BatchOperationType op)
Sets the batch operation to execute in a BaseEntry . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BatchUtils()
Method Detail |
---|
public static void declareExtensions(ExtensionProfile extProfile)
extProfile
- extensionProfilepublic static void declareFeedExtensions(ExtensionProfile extProfile)
extProfile
- public static void declareEntryExtensions(ExtensionProfile extProfile)
extProfile
- public static java.lang.String getBatchId(BaseEntry<?> entry)
<batch:id>
.
entry
-
public static void setBatchId(ExtensionPoint extPoint, java.lang.String id)
<batch:id>
.
extPoint
- extension point to put the id onid
- the batch id or null to remove itpublic static BatchOperationType getBatchOperationType(ExtensionPoint extPoint)
<batch:operation>
in a ExtensionPoint
.
extPoint
- extension point to get the operation type from
public static void setBatchOperationType(ExtensionPoint extPoint, BatchOperationType op)
BaseEntry
.
extPoint
- extension point to set the operation type onop
- batch operation type or null to remove itpublic static BatchInterrupted getBatchInterrupted(ExtensionPoint extPoint)
<batch:interrupted>
.
extPoint
- the extension point to get the interrupted tag from
public static BatchStatus getBatchStatus(ExtensionPoint extPoint)
<batch:status>
.
extPoint
- the extension point to get the status from
public static boolean isSuccess(ExtensionPoint extPoint)
BatchStatus
object.
extPoint
- the extension point to check the status on.
java.lang.IllegalArgumentException
- if the entry does not contain
a BatchStatus object.public static boolean isFailure(ExtensionPoint extPoint)
BatchStatus
object.
You'll want to call getBatchStatus(ExtensionPoint)
to get the error description and message when this
method returns true.
extPoint
- the extension point to check the status of.
java.lang.IllegalArgumentException
- if the entry does not contain
a BatchStatus object.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |