Class DataArray
java.lang.Object
studio.magemonkey.codex.mccore.config.parse.DataArray
Represents a section of a config
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds a value to the arrayGets the array as a data section listGets the array as a string listvoidclear()Clears all data and comments from the data sectionget(int index) Fetches a value using an indexintsize()values()Retrieves the values contained in the keys for this section
-
Constructor Details
-
DataArray
public DataArray()
-
-
Method Details
-
clear
public void clear()Clears all data and comments from the data section -
size
public int size()- Returns:
- number of key/value pairs
-
values
Retrieves the values contained in the keys for this section- Returns:
- values contained in the keys for this section
-
add
Adds a value to the array- Parameters:
value- value to add
-
get
Fetches a value using an index- Parameters:
index- index to use- Returns:
- fetched value
-
asStringList
Gets the array as a string list- Returns:
- string list representation
-
asDataList
Gets the array as a data section list- Returns:
- data list representation
-