Annotation Interface ElementService
@Target(PACKAGE)
@Retention(RUNTIME)
@Repeatable(ElementServices.class)
public @interface ElementService
Defines a service provided by the element. This annotation must accompany the same
Package
which bears the
ElementDefinition
, or else it will be ignored.
If the ElementServiceExport
appears directly on a type, then this does not need to appear on the package
definition as well. This is useful for when a element may export services in third-party libraries where it may not
be able to modify the original code. (eg, when the database element exposes the raw JDBC object it uses).-
Required Element Summary
Required Elements -
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionSpecifies theElementServiceExport
for this particualrElementService
.Specifies theElementServiceImplementation
for the type.
-
Element Details
-
value
Class<?> valueThe service interface type.- Returns:
- the implementation type
-
export
ElementServiceExport exportSpecifies theElementServiceExport
for this particualrElementService
.- Returns:
- the
ElementServiceExport
- Default:
@dev.getelements.elements.sdk.annotation.ElementServiceExport
-
implementation
ElementServiceImplementation implementationSpecifies theElementServiceImplementation
for the type.- Returns:
- the implementation specification
- Default:
@dev.getelements.elements.sdk.annotation.ElementServiceImplementation
-