Package org.openhab.core.voice.text
Record Class AbstractRuleBasedInterpreter.ItemFilter
java.lang.Object
java.lang.Record
org.openhab.core.voice.text.AbstractRuleBasedInterpreter.ItemFilter
- Enclosing class:
- AbstractRuleBasedInterpreter
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionall()
final boolean
Indicates whether some other object is "equal to" this one.Returns the value of theexcludedItemNames
record component.boolean
filterItem
(Item item, MetadataRegistry metadataRegistry) forSimilarItem
(Item item, @Nullable Metadata semantic) final int
hashCode()
Returns a hash code value for this object.Returns the value of theitemNames
record component.Returns the value of theitemSemantics
record component.itemTags()
Returns the value of theitemTags
record component.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
ItemFilter
public ItemFilter(Set<String> itemNames, Set<String> excludedItemNames, Set<String> itemTags, Set<String> itemSemantics) Creates an instance of aItemFilter
record class.- Parameters:
itemNames
- the value for theitemNames
record componentexcludedItemNames
- the value for theexcludedItemNames
record componentitemTags
- the value for theitemTags
record componentitemSemantics
- the value for theitemSemantics
record component
-
-
Method Details
-
filterItem
-
all
-
forItem
-
forItems
-
forSimilarItem
public static AbstractRuleBasedInterpreter.ItemFilter forSimilarItem(Item item, @Nullable Metadata semantic) -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
itemNames
Returns the value of theitemNames
record component.- Returns:
- the value of the
itemNames
record component
-
excludedItemNames
Returns the value of theexcludedItemNames
record component.- Returns:
- the value of the
excludedItemNames
record component
-
itemTags
Returns the value of theitemTags
record component.- Returns:
- the value of the
itemTags
record component
-
itemSemantics
Returns the value of theitemSemantics
record component.- Returns:
- the value of the
itemSemantics
record component
-