public static Formula create(Ptg[] ptgs) {if (ptgs == null || ptgs.length < 1) {return EMPTY;}int totalSize = Ptg.getEncodedSize(ptgs);byte[] encodedData = new byte[totalSize];Ptg.serializePtgs(ptgs, encodedData, 0);int encodedTokenLen = Ptg.getEncodedSizeWithoutArrayData(ptgs);return new Formula(encodedData, encodedTokenLen);}

public static Formula Create(Ptg[] ptgs){if (ptgs == null || ptgs.Length < 1){return EMPTY;}int totalSize = Ptg.GetEncodedSize(ptgs);byte[] encodedData = new byte[totalSize];Ptg.SerializePtgs(ptgs, encodedData, 0);int encodedTokenLen = Ptg.GetEncodedSizeWithoutArrayData(ptgs);return new Formula(encodedData, encodedTokenLen);}
