Class MetadataReader
- java.lang.Object
-
- org.rodnansol.core.generator.reader.MetadataReader
-
public class MetadataReader extends Object
Reads the spring-configuration-metadata.json file.- Since:
- 0.1.0
- Author:
- nandorholozsnyak
-
-
Field Summary
Fields Modifier and Type Field Description static MetadataReaderINSTANCE
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,List<Property>>readPropertiesAsMap(InputStream metadataStream)Returns the properties in a map where the key is the name of the properties key and the values is the associated properties.List<PropertyGroup>readPropertiesAsPropertyGroupList(InputStream metadataStream)Returns a list ofPropertyGroupinstances from the given input stream.
-
-
-
Field Detail
-
INSTANCE
public static final MetadataReader INSTANCE
-
-
Method Detail
-
readPropertiesAsMap
public Map<String,List<Property>> readPropertiesAsMap(InputStream metadataStream)
Returns the properties in a map where the key is the name of the properties key and the values is the associated properties.- Parameters:
metadataStream- stream containing the content of thespring-configuration-metadata.json.- Returns:
- groups and properties converted to a Map.
- Since:
- 0.1.0
-
readPropertiesAsPropertyGroupList
public List<PropertyGroup> readPropertiesAsPropertyGroupList(InputStream metadataStream)
Returns a list ofPropertyGroupinstances from the given input stream.NOTE: The current implementation is a bit fuzzy, when the time comes we can come up with a more efficient solution, but right now this is the "contact" basically.
- Parameters:
metadataStream- stream containing the content of thespring-configuration-metadata.json.- Returns:
- groups and properties converted to a List of
PropertyGroup. - Since:
- 0.1.0
-
-