Class JsonAPITableFormat
- java.lang.Object
-
- com.github.dannil.scbjavaclient.format.json.JsonAPITableFormat
-
- All Implemented Interfaces:
ITableFormat
public class JsonAPITableFormat extends Object implements ITableFormat
Class which encapsulates behavior for the JSON API table format. Note that this class is immutable; to change the containing JSON, a new class needs to be instantiated.
- Since:
- 0.1.0
-
-
Constructor Summary
Constructors Constructor Description JsonAPITableFormat(String json)
Default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,Collection<String>>
getPairs()
Extracts the keys and their respective values from the data.String
toString()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.github.dannil.scbjavaclient.format.ITableFormat
getKeys, getValues
-
-
-
-
Constructor Detail
-
JsonAPITableFormat
public JsonAPITableFormat(String json)
Default constructor.
- Parameters:
json
- the JSON to format
-
-
Method Detail
-
getPairs
public Map<String,Collection<String>> getPairs()
Description copied from interface:ITableFormat
Extracts the keys and their respective values from the data.
- Specified by:
getPairs
in interfaceITableFormat
- Returns:
- a
Map
of all keys and their respective values
-
-