T - this class to chain method callspublic class FluentLabelImpl<T> extends java.lang.Object implements FluentLabel<T>, FluentLabelProvider
| Constructor and Description |
|---|
FluentLabelImpl(T reference,
java.util.function.Supplier<java.lang.String> defaultLabelSupplier)
Creates a new fluent label.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getLabel()
Get the defined label.
|
java.lang.String[] |
getLabelHints()
Get the defined label hints.
|
java.lang.String |
toString() |
T |
withLabel(java.lang.String label)
Apply a label that will be displayed as the representation of this object for error message.
|
T |
withLabelHint(java.lang.String... labelHint)
Add a label hint that will be appended to the representation of this object for error message.
|
public FluentLabelImpl(T reference, java.util.function.Supplier<java.lang.String> defaultLabelSupplier)
reference - object reference to chain methods calls.defaultLabelSupplier - supplier for default label to display when no label is defined.public T withLabel(java.lang.String label)
FluentLabelwithLabel in interface FluentLabel<T>label - label to usepublic java.lang.String getLabel()
getLabel in interface FluentLabelProviderpublic T withLabelHint(java.lang.String... labelHint)
FluentLabelwithLabelHint in interface FluentLabel<T>labelHint - label hints to addpublic java.lang.String[] getLabelHints()
getLabelHints in interface FluentLabelProviderpublic java.lang.String toString()
toString in class java.lang.ObjectCopyright © 2018 FluentLenium. All Rights Reserved.