Class PetstoreConflictException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.apache.juneau.petstore.service.PetstoreConflictException
All Implemented Interfaces:
Serializable

Thrown when a petstore operation conflicts with the entity's current state (HTTP 409 at the console layer).
Example:

if (pet.getStatus() == PetStatus.SOLD) throw new PetstoreConflictException("Pet '%s' is already '%s'", pet.getId(), pet.getStatus());

See Also: