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
ConstructorsModifierConstructorDescriptionprotected
ServiceCapability
(String id, ServiceCapabilityType type, String title, String description) -
Method Summary
Modifier and TypeMethodDescriptionabstract T
Return the "content" of this capability.getId()
getTitle()
getType()
void
merge
(ServiceCapability<T> other) Merge this capability with the specified argument.abstract void
Merge the content of this instance with the specified content.void
setDescription
(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 thetype
of 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 sameid
andtype
). Sub-classes may merge additional content.- Parameters:
other
- the content to merge
-