Class JsonConfigurationReader
- java.lang.Object
-
- org.infinispan.commons.configuration.io.AbstractConfigurationReader
-
- org.infinispan.commons.configuration.io.json.JsonConfigurationReader
-
- All Implemented Interfaces:
AutoCloseable
,ConfigurationReader
public class JsonConfigurationReader extends AbstractConfigurationReader
- Since:
- 12.1
- Author:
- Tristan Tarrant <[email protected]>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.infinispan.commons.configuration.io.ConfigurationReader
ConfigurationReader.Builder, ConfigurationReader.ElementType
-
-
Field Summary
-
Fields inherited from class org.infinispan.commons.configuration.io.AbstractConfigurationReader
namingStrategy
-
-
Constructor Summary
Constructors Constructor Description JsonConfigurationReader(BufferedReader reader, ConfigurationResourceResolver resourceResolver, Properties properties, PropertyReplacer replacer, NamingStrategy namingStrategy)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
endMapItem()
int
getAttributeCount()
String
getAttributeName(int index, NamingStrategy strategy)
String
getAttributeNamespace(int index)
String
getAttributeValue(int index)
String
getAttributeValue(String name, NamingStrategy strategy)
String
getElementText()
String[]
getListAttributeValue(int index)
Get the value of an attribute as a space-delimited string list.String
getLocalName(NamingStrategy strategy)
Location
getLocation()
Map.Entry<String,String>
getMapItem(String nameAttribute)
String
getNamespace()
boolean
hasFeature(ConfigurationFormatFeature feature)
boolean
hasNext()
ConfigurationReader.ElementType
nextElement()
String[]
readArray(String outer, String inner)
void
require(ConfigurationReader.ElementType type, String namespace, String name)
-
Methods inherited from class org.infinispan.commons.configuration.io.AbstractConfigurationReader
getAttributeName, getAttributeValue, getLocalName, getMapItem, getNamingStrategy, getProperties, getProperty, getResourceResolver, getSchema, handleAny, handleAttribute, readArray, replaceProperties, setSchema
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.infinispan.commons.configuration.io.ConfigurationReader
getAttributeValue, getAttributeValue, inTag, inTag, inTag, require, require
-
-
-
-
Constructor Detail
-
JsonConfigurationReader
public JsonConfigurationReader(BufferedReader reader, ConfigurationResourceResolver resourceResolver, Properties properties, PropertyReplacer replacer, NamingStrategy namingStrategy)
-
-
Method Detail
-
nextElement
public ConfigurationReader.ElementType nextElement()
- Returns:
- the next element
-
getLocation
public Location getLocation()
-
getAttributeName
public String getAttributeName(int index, NamingStrategy strategy)
-
getLocalName
public String getLocalName(NamingStrategy strategy)
-
getAttributeNamespace
public String getAttributeNamespace(int index)
-
getAttributeValue
public String getAttributeValue(String name, NamingStrategy strategy)
-
getListAttributeValue
public String[] getListAttributeValue(int index)
Description copied from interface:ConfigurationReader
Get the value of an attribute as a space-delimited string list.- Parameters:
index
- the index of the attribute
-
getAttributeValue
public String getAttributeValue(int index)
-
getElementText
public String getElementText()
-
getNamespace
public String getNamespace()
-
hasNext
public boolean hasNext()
-
getAttributeCount
public int getAttributeCount()
-
require
public void require(ConfigurationReader.ElementType type, String namespace, String name)
-
endMapItem
public void endMapItem()
-
hasFeature
public boolean hasFeature(ConfigurationFormatFeature feature)
-
close
public void close()
-
-