- All Known Subinterfaces:
DescriptorHandler
public interface DescriptorMetadata
Metadata of a service descriptor, as stored in Helidon specific file "META-INF/helidon/service-registry.json".
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionContracts of the service.static DescriptorMetadata
Create a new instance from descriptor information, i.e.Descriptor type name.Type of registry, such ascore
.toHson()
Create the metadata in Helidon metadata format.double
weight()
Weight of the service.
-
Field Details
-
REGISTRY_TYPE_CORE
registryType()
for core services.- See Also:
-
-
Method Details
-
create
static DescriptorMetadata create(String registryType, TypeName descriptor, double weight, Set<TypeName> contracts) Create a new instance from descriptor information, i.e. when code generating the descriptor metadata.- Parameters:
registryType
- type of registry, such asREGISTRY_TYPE_CORE
descriptor
- type of the service descriptor (the generated file fromhelidon-service-codegen
)weight
- weight of the service descriptorcontracts
- contracts the service implements- Returns:
- a new descriptor metadata instance
-
registryType
String registryType()Type of registry, such ascore
.- Returns:
- registry type this descriptor is created for
-
descriptorType
TypeName descriptorType()Descriptor type name.- Returns:
- descriptor type
-
contracts
Contracts of the service.- Returns:
- contracts the service implements/provides.
-
weight
double weight()Weight of the service.- Returns:
- service weight
- See Also:
-
toHson
Hson.Struct toHson()Create the metadata in Helidon metadata format. This is used by components that store the metadata.- Returns:
- HSON object (similar to JSON)
-