Package one.jpro.platform.image.manager
Class ImageDefinition
java.lang.Object
one.jpro.platform.image.manager.ImageDefinition
- All Implemented Interfaces:
JsonConvertible
Represents a definition of an image that encompasses its source, transformation, and encoding details.
This class also provides the capability to convert its instance into a JSON representation.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionImageDefinition(ImageSource source, ImageTransformer transformer, ImageEncoder encoder) Constructs a new instance of ImageDefinition. -
Method Summary
Modifier and TypeMethodDescriptionReturns the image encoder associated with this definition.Returns the image source associated with this definition.Returns the image transformer associated with this definition.org.json.JSONObjecttoJSON()Converts the object to a JSON representation.
-
Constructor Details
-
ImageDefinition
Constructs a new instance of ImageDefinition.- Parameters:
source- The source of the image.transformer- The transformer for the image.encoder- The encoder for the image.
-
-
Method Details
-
toJSON
public org.json.JSONObject toJSON()Description copied from interface:JsonConvertibleConverts the object to a JSON representation.- Specified by:
toJSONin interfaceJsonConvertible- Returns:
- A JSONObject representing the object.
-
getSource
Returns the image source associated with this definition.- Returns:
- The
ImageSourceinstance.
-
getTransformer
Returns the image transformer associated with this definition.- Returns:
- The
ImageTransformerinstance.
-
getEncoder
Returns the image encoder associated with this definition.- Returns:
- The
ImageEncoderinstance.
-