Package io.spring.initializr.metadata
Class ServiceCapability<T>
java.lang.Object
io.spring.initializr.metadata.ServiceCapability<T>
- Type Parameters:
T- the content type
- All Implemented Interfaces:
Cloneable
- Direct Known Subclasses:
DependenciesCapability,SingleSelectCapability,TextCapability,TypeCapability
Defines a capability of the initializr service. Each capability is defined by a id and
a
type.- Author:
- Stephane Nicoll
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedServiceCapability(String id, ServiceCapabilityType type, String title, String description) -
Method Summary
Modifier and TypeMethodDescriptionabstract TReturn the "content" of this capability.getId()getTitle()getType()voidmerge(ServiceCapability<T> other) Merge this capability with the specified argument.abstract voidMerge the content of this instance with the specified content.voidsetDescription(String description) void
-
Constructor Details
-
ServiceCapability
protected ServiceCapability(String id, ServiceCapabilityType type, String title, String description)
-
-
Method Details
-
getTitle
-
setTitle
-
getDescription
-
setDescription
-
getId
-
getType
-
getContent
Return the "content" of this capability. The structure of the content vastly depends on thetypeof the capability.- Returns:
- the content
-
merge
Merge the content of this instance with the specified content.- Parameters:
otherContent- the content to merge- See Also:
-
merge
Merge this capability with the specified argument. The service capabilities should match (i.e have the sameidandtype). Sub-classes may merge additional content.- Parameters:
other- the content to merge
-