Interface ReservationState
- All Superinterfaces:
JsonEnum
- All Known Implementing Classes:
ReservationState.ReservationStateEnum
Status of the Reservation.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumpossible values of ReservationState -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ReservationStateThe quantity of the item has been allocated for fulfillment.static final ReservationStateTheavailableQuantityof the item has been reduced by the reserved quantity, but thequantityOnStockremains unchanged.static final ReservationStateThe reservation has expired and theavailableQuantityis increased accordingly.static final ReservationStateThe reserved quantity of the item has been released.static final ReservationStateThe reservation has been updated. -
Method Summary
Modifier and TypeMethodDescriptionstatic ReservationStatefactory method for a enum value of ReservationState if no enum has been found an anonymous instance will be createdstatic Optional<ReservationState>findEnumViaJsonName(String jsonName) method to find enum using the JSON valuethe JSON valuename()the enum valuetoString()convert value to stringstatic ReservationState[]values()possible enum values
-
Field Details
-
CREATED
The
availableQuantityof the item has been reduced by the reserved quantity, but thequantityOnStockremains unchanged. -
UPDATED
The reservation has been updated. If the quantity of an item changed, the
availableQuantityis increased or decreased accordingly, while thequantityOnStockremains unchanged. -
RELEASED
The reserved quantity of the item has been released. The
availableQuantityis increased accordingly. -
EXPIRED
The reservation has expired and the
availableQuantityis increased accordingly. Reservation expirations are eventually consistent, meaning it can take a few minutes for the status to update after expiration. -
COMMITTED
The quantity of the item has been allocated for fulfillment. The
quantityOnStockhas been reduced by the reserved quantity.
-
-
Method Details
-
getJsonName
String getJsonName()the JSON value- Specified by:
getJsonNamein interfaceJsonEnum- Returns:
- json value
-
name
String name()the enum value -
toString
String toString()convert value to string -
findEnum
factory method for a enum value of ReservationState if no enum has been found an anonymous instance will be created- Parameters:
value- the enum value to be wrapped- Returns:
- enum instance
-
findEnumViaJsonName
method to find enum using the JSON value- Parameters:
jsonName- the json value to be wrapped- Returns:
- optional of enum instance
-
values
possible enum values- Returns:
- array of possible enum values
-