Interface ReadableStringValue
-
- All Superinterfaces:
ReadableSimpleValue<String>
,ReadableTypedValue<String>
,ReadableValue<String>
,Supplier<String>
- All Known Subinterfaces:
ObservableStringValue
,ReadableStringProperty
,StringExpression
,WritableStringProperty
,WritableStringValue
- All Known Implementing Classes:
StringBinding
,StringListProperty
,StringProperty
public interface ReadableStringValue extends ReadableSimpleValue<String>
- Since:
- 1.0.0
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default String
getAsString()
default String
getSafe()
default String
getValue()
Same asReadableValue.get()
.default Class<String>
getValueClass()
-
Methods inherited from interface io.github.mmm.value.ReadableValue
get
-
-
-
-
Method Detail
-
getAsString
default String getAsString()
- Specified by:
getAsString
in interfaceReadableSimpleValue<String>
- Returns:
- the
value
asString
.
-
getValueClass
default Class<String> getValueClass()
- Specified by:
getValueClass
in interfaceReadableTypedValue<String>
- Returns:
- the
Class
reflecting the type ofvalues
that can be stored by this property. Even if thevalue
isnull
the property must support returning the property class.
-
getValue
default String getValue()
Same asReadableValue.get()
.- Returns:
- the current
value
.
-
getSafe
default String getSafe()
- Specified by:
getSafe
in interfaceReadableValue<String>
- Returns:
- the same as
ReadableValue.get()
but trying to avoid returningnull
where possible. So a neutral element is returned instead ofnull
for each type supporting this (e.g. "" forString
,0
for any kind ofNumber
,Boolean.FALSE
, empty collection, etc.).
-
-