3 import java.util.ArrayList;
5 public class ChemiCraftAPI {
7 public static ChemiCraftAPI instance = new ChemiCraftAPI();
9 private boolean addLanguage = false;
10 private static ArrayList<String> compoundsNameList = new ArrayList();
11 private static ArrayList<String> compoundsLangNameList = new ArrayList();
12 private static ArrayList<String> compoundsLangList = new ArrayList();
13 private static ArrayList<ICompoundHandler> compoundHandlers = new ArrayList<ICompoundHandler>();
14 private static ArrayList<String> compoundHandlerItemNames = new ArrayList<String>();
16 public static void addCompound(String name){
17 compoundsNameList.add(name);
18 compoundsLangNameList.add("");
19 compoundsLangList.add("");
22 public static void addLangCompound(String lang, String englishName, String langName){
23 compoundsNameList.add(englishName);
24 compoundsLangNameList.add(langName);
25 compoundsLangList.add(lang);
28 public static ArrayList<String> getCompoundsName(){
29 compoundsNameList.trimToSize();
30 return compoundsNameList;
33 public static ArrayList<String> getCompoundsLangName(){
34 compoundsLangNameList.trimToSize();
35 return compoundsLangNameList;
38 public static ArrayList<String> getCompoundsLang(){
39 compoundsLangList.trimToSize();
40 return compoundsLangList;
43 public static void addCompoundHandler(String handlerItemName, ICompoundHandler compoundHandler){
44 ChemiCraftAPI.compoundHandlers.add(compoundHandler);
45 compoundHandlerItemNames.add(handlerItemName);
48 public static ArrayList<ICompoundHandler> getCompoundHandler(){
49 compoundHandlers.trimToSize();
50 return compoundHandlers;
54 public static ArrayList<String> getCompoundHandlerItemName(){
55 compoundHandlerItemNames.trimToSize();
56 return compoundHandlerItemNames;