-
public interface StructuredFormatFactory
Factory to create instances ofStructuredFormat
.
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default StructuredFormat
create(String format)
default StructuredFormat
create(String format, MarshallingConfig config)
static StructuredFormatFactory
get()
StructuredFormatProvider
getProvider(String format)
-
-
-
Method Detail
-
getProvider
StructuredFormatProvider getProvider(String format)
- Parameters:
format
- theformat name
. E.g.JSON
,XML
, orYAML
.- Returns:
- a new
StructuredFormatProvider
for the givenformat
ornull
if no such provider is registered. - Throws:
ObjectNotFoundException
- if no such provider could be found.
-
create
default StructuredFormat create(String format)
- Parameters:
format
- theformat name
. E.g.JSON
,XML
, orYAML
.- Returns:
- a new
StructuredFormat
for the givenformat
using default configuration.
-
create
default StructuredFormat create(String format, MarshallingConfig config)
- Parameters:
format
- theformat name
. E.g.JSON
,XML
, orYAML
.config
- theMarshallingConfig
to customize the format.- Returns:
- a new
StructuredFormat
for the givenformat
using the givenconfig
. - See Also:
StructuredFormatProvider.create(MarshallingConfig)
-
get
static StructuredFormatFactory get()
- Returns:
- the instance of this
StructuredFormatFactory
.
-
-