public class BatchUtils
extends java.lang.Object
| Constructor and Description |
|---|
BatchUtils() |
| Modifier and Type | Method and Description |
|---|---|
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. |
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 frompublic 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 frompublic static BatchStatus getBatchStatus(ExtensionPoint extPoint)
<batch:status>.extPoint - the extension point to get the status frompublic 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.