public interface ISettingsList extends List<Object>
SettingsListBuilder
.Modifier and Type | Method and Description |
---|---|
Map<String,Object> |
asFlatValuesMap() |
Map<String,Object> |
asFlatValuesMap(String indexedBy) |
String |
asJsonString() |
String |
asJsonString(IJsonSerializer s)
This variant accept a serializer to deal with unsupported types.
|
List<ISettingsMap> |
asSettingsMapList() |
List<String> |
asStringSettingsList() |
Boolean |
getAsBoolean(int index) |
Integer |
getAsInteger(int index) |
Long |
getAsLong(int index) |
ISettingsList |
getAsSettingsList(int index)
Return the ith element of a list, expecting it to be a
ISettingsList . |
ISettingsMap |
getAsSettingsMap(int index)
Return the ith element of a list, expecting it to be a
ISettingsMap . |
String |
getAsString(int index) |
String |
getOriginatorName() |
void |
setOriginatorName(String name) |
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray
parallelStream, removeIf, stream
List<String> asStringSettingsList()
UnexpectedSettingTypeException
- if any item is not a stringList<ISettingsMap> asSettingsMapList()
UnexpectedSettingTypeException
- if any item is not a SettingsMapBoolean getAsBoolean(int index)
index
- the element indexUnexpectedSettingTypeException
- runtime exception if requested type is not actual type of non-null propertyString getAsString(int index)
index
- the element indexUnexpectedSettingTypeException
- runtime exception if requested type is not actual type of non-null propertyLong getAsLong(int index)
index
- the element indexUnexpectedSettingTypeException
- runtime exception if requested type is not actual type of non-null propertyInteger getAsInteger(int index)
index
- the element indexUnexpectedSettingTypeException
- runtime exception if requested type is not actual type of non-null propertyISettingsList getAsSettingsList(int index)
ISettingsList
.index
- the element indexUnexpectedSettingTypeException
- runtime exception if requested type is not actual type of non-null propertyISettingsMap getAsSettingsMap(int index)
ISettingsMap
.index
- the element indexUnexpectedSettingTypeException
- runtime exception if requested type is not actual type of non-null propertyvoid setOriginatorName(String name)
name
- that should be used to identify naming context in exception/log strings
by default, name is class name.String getOriginatorName()
Map<String,Object> asFlatValuesMap()
Map<String,Object> asFlatValuesMap(String indexedBy)
indexedBy
- a character that will be used as seperatorString asJsonString()
String asJsonString(IJsonSerializer s)
s
- your serializerCopyright © 2014–2023. All rights reserved.