Interface NamedOperation
- All Superinterfaces:
org.springframework.core.Ordered
public interface NamedOperation
extends org.springframework.core.Ordered
NamedOperation
is an interface that can be implemented to add group of operation.
public class CustomNamedOperation implements NamedOperation { private static final Map<String, String> CUSTOM_NAMED_OPERATIONS = new HashMap<String, String>(){{ put("resize", "400x200"); put("crop", "120x120+10+5"); }}; {@code @Override} public String getName() { return "customName"; } {@code @Override} public Map<String, String> getOperations() { return CUSTOM_NAMED_OPERATIONS; } }
@Bean
public NamedOperation customNamedOperation() { return new CustomNamedOperation(); }
- Author:
- Dima Myroniuk (dmyroniuk)
- See Also:
-
Field Summary
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
-
Method Summary
-
Method Details
-
getOrder
default int getOrder()- Specified by:
getOrder
in interfaceorg.springframework.core.Ordered
-
getName
String getName()Get the name ofNamedOperation
- Returns:
- the name of
NamedOperation
-
getOperations
Get the theMap
of operations NOTE: the key of this map should be one of the ImageMagick operations that configured by the property broadleaf.image.availableEffects- Returns:
- the
Map
of operations
-