public class CsvTypeLoader extends Object implements TypeLoader
MetadataType
from the RAML must be of only
some valid field types, see VALID_FIELD_TYPES
Modifier and Type | Field and Description |
---|---|
static List<Class<? extends MetadataType>> |
VALID_FIELD_TYPES |
Constructor and Description |
---|
CsvTypeLoader(File ramlFile)
Constructs a CSV type loader from a RAML document
|
CsvTypeLoader(String content,
String ramlLocation)
Constructs a CSV type loader from a RAML document
|
Modifier and Type | Method and Description |
---|---|
Optional<MetadataType> |
load(String typeIdentifier)
Returns the MetadataType of the specified identifier if found
|
Optional<MetadataType> |
load(String typeIdentifier,
String typeAlias)
Returns the MetadataType of the specified identifier if found, optionally assigning specified type alias
|
public static final List<Class<? extends MetadataType>> VALID_FIELD_TYPES
public CsvTypeLoader(File ramlFile)
ramlFile
- file pointing to the RAML resourcepublic Optional<MetadataType> load(String typeIdentifier)
TypeLoader
load
in interface TypeLoader
typeIdentifier
- The identifier namepublic Optional<MetadataType> load(String typeIdentifier, String typeAlias)
TypeLoader
load
in interface TypeLoader
typeIdentifier
- The identifier nametypeAlias
- The nullable type aliasCopyright © 2018. All rights reserved.