Class DestinationOption
java.lang.Object
ecmwf.ecpds.master.transfer.DestinationOption
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classEntry for each type. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDestinationOption(Destination destination) Instantiates a new destination option. -
Method Summary
Modifier and TypeMethodDescriptionbooleanDelete from spool on expiration.booleanDelete from spool on success.static booleanexists(int id) Check if the id exists.static StringformatDate(Destination destination, long date) Format the date according to the format specified in the Destination, or the default one if it is not specified.static StringgetLabel(int id) Get the label for an id.static StringGet the label for an id.static List<DestinationOption.TypeEntry> getList()Gets the list.static DestinationOption.TypeEntrygetTypeEntry(String label) Get the type entry for a label.static StringgetTypeIds(String category) Gets the list of ids for the selected category.getTypes(boolean addAllSelectors) Get the type list ordered by the pos field.booleanIf target exist overwrite.booleanIf target exist resume.static booleanisAcquisition(int id) Checks if is acquisition.static booleanisDissemination(int id) Checks if is dissemination.static booleanisTimeCritical(int id) Checks if is time critical.booleanOn host failure next and retry.booleanOn host failure next and stay.static longparseDate(Destination destination, String date) Parse the date according to the format specified in the Destination, or the default one if it is not specified.static voidSets the list.
-
Field Details
-
UNKNOWN_TYPE
-
TYPE_USER_AND_GROUP
-
deleteFromSpool
-
ifTargetExist
-
onHostFailure
-
-
Constructor Details
-
DestinationOption
Instantiates a new destination option.- Parameters:
destination- the destination
-
-
Method Details
-
getList
-
setList
Sets the list.- Parameters:
list- the new list
-
getTypes
-
exists
public static boolean exists(int id) Check if the id exists.- Parameters:
id- the id- Returns:
- if it exists
-
getLabel
-
getTypeEntry
Get the type entry for a label.- Parameters:
label- the label- Returns:
- the type entry for the label
-
getLabel
Get the label for an id.- Parameters:
id- the id- Returns:
- the label for the id
-
isAcquisition
public static boolean isAcquisition(int id) Checks if is acquisition.- Parameters:
id- the id- Returns:
- true, if is acquisition
-
isDissemination
public static boolean isDissemination(int id) Checks if is dissemination.- Parameters:
id- the id- Returns:
- true, if is dissemination
-
isTimeCritical
public static boolean isTimeCritical(int id) Checks if is time critical.- Parameters:
id- the id- Returns:
- true, if is time critical
-
getTypeIds
-
ifTargetExistResume
public boolean ifTargetExistResume()If target exist resume.- Returns:
- true, if successful
-
ifTargetExistOverwrite
public boolean ifTargetExistOverwrite()If target exist overwrite.- Returns:
- true, if successful
-
deleteFromSpoolOnSuccess
public boolean deleteFromSpoolOnSuccess()Delete from spool on success.- Returns:
- true, if successful
-
deleteFromSpoolOnExpiration
public boolean deleteFromSpoolOnExpiration()Delete from spool on expiration.- Returns:
- true, if successful
-
onHostFailureNextAndRetry
public boolean onHostFailureNextAndRetry()On host failure next and retry.- Returns:
- true, if successful
-
onHostFailureNextAndStay
public boolean onHostFailureNextAndStay()On host failure next and stay.- Returns:
- true, if successful
-
parseDate
Parse the date according to the format specified in the Destination, or the default one if it is not specified.- Parameters:
destination- the formatted datedate- the date- Returns:
- the date
-
formatDate
Format the date according to the format specified in the Destination, or the default one if it is not specified.- Parameters:
destination- the datedate- the date- Returns:
- the formatted date
-