Package org.openhab.core.thing.type
Class ChannelGroupTypeBuilder
java.lang.Object
org.openhab.core.thing.type.ChannelGroupTypeBuilder
A
ChannelGroupType builder.- Author:
- Christoph Weitkamp - Initial contribution, Christoph Weitkamp - Removed "advanced" attribute
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Build theChannelGroupTypewith the given valuesstatic ChannelGroupTypeBuilderinstance(ChannelGroupTypeUID channelGroupTypeUID, String label) Create an instance of a ChannelGroupTypeBuilder forChannelGroupTypeswithCategory(String category) Sets the category for theChannelGroupTypewithChannelDefinitions(List<ChannelDefinition> channelDefinitions) Sets the channels for theChannelGroupTypewithDescription(String description) Sets the description for theChannelGroupType
-
Method Details
-
instance
public static ChannelGroupTypeBuilder instance(ChannelGroupTypeUID channelGroupTypeUID, String label) Create an instance of a ChannelGroupTypeBuilder forChannelGroupTypes- Parameters:
channelGroupTypeUID- UID of theChannelGroupTypelabel- Label for theChannelGroupType- Returns:
- ChannelGroupTypeBuilder for
ChannelGroupTypes
-
build
Build theChannelGroupTypewith the given values- Returns:
- the created
ChannelGroupType
-
withDescription
Sets the description for theChannelGroupType- Parameters:
description- Description for theChannelGroupType- Returns:
- this Builder
-
withCategory
Sets the category for theChannelGroupType- Parameters:
category- Category for theChannelGroupType- Returns:
- this Builder
-
withChannelDefinitions
Sets the channels for theChannelGroupType- Parameters:
channelDefinitions- The channels thisChannelGroupTypeprovides (could be null or empty)- Returns:
- this Builder
-