Annotation Interface MetadataKeyId
@MinMuleVersion("4.1")
@Target({PARAMETER,FIELD})
@Retention(RUNTIME)
@Documented
public @interface MetadataKeyId
Marks one of the parameters of an Operation or Source as the key for the metadata lookup. This lookup is resolved by the
TypeKeysResolver referenced in the MetadataScope, at Operation, Source or Extension level, which will return
the list of available the MetadataKey or also, the lookup can be resolved by the
QueryEntityResolver.getEntityKeys(MetadataContext) for Query annotated operations, this time the key will
represent the query (DSQL or Native) which is used to calculate the output metadata.
Annotation Usage:
- Operations: The annotation must be applied to an Operation parameter to mark it as the metadata key parameter. The usage of this annotation in multiple parameters of the same operation or fields of the operation class is not allowed.
- Sources: The annotation must be applied to a Source field annotated with
Parameterto mark it as the metadata key parameter. The usage of this annotation in a nonParameterfield, multiple fields or in a method parameter, is not allowed.
- Since:
- 1.0
-
Optional Element Summary
Optional Elements
-
Element Details
-
value
Class<? extends org.mule.runtime.api.metadata.resolving.TypeKeysResolver> value- Returns:
- the associated
TypeKeysResolverfor the annotated Component
- Default:
- org.mule.runtime.extension.api.metadata.NullMetadataResolver.class
-