Class AvailableInAnotherContextException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
-
- org.gcube.informationsystem.resourceregistry.api.exceptions.instances.AvailableInAnotherContextException
-
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
EntityAvailableInAnotherContextException,RelationAvailableInAnotherContextException
public class AvailableInAnotherContextException extends ResourceRegistryException
Base exception thrown when the requested instance exists, but only in a Context other than the one scoping the request — a visibility boundary violation distinct fromNotFoundException(element genuinely absent). Specialized per element kind (e.g.EntityAvailableInAnotherContextException), and also thrown directly as a generic fallback. Mapped to403 Forbiddenby the REST layer.- Author:
- Luca Frosini (ISTI - CNR)
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AvailableInAnotherContextException(String message)Instantiates a new available in another context exception.AvailableInAnotherContextException(String message, Throwable cause)Instantiates a new available in another context exception.AvailableInAnotherContextException(Throwable cause)Instantiates a new available in another context exception.
-
Method Summary
-
Methods inherited from class org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
getResponseMetadata, withResponseMetadata
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
AvailableInAnotherContextException
public AvailableInAnotherContextException(String message)
Instantiates a new available in another context exception.- Parameters:
message- the message
-
AvailableInAnotherContextException
public AvailableInAnotherContextException(Throwable cause)
Instantiates a new available in another context exception.- Parameters:
cause- the cause
-
-