Skip to content

Commit

Permalink
improve comments
Browse files Browse the repository at this point in the history
  • Loading branch information
esaulpaugh committed Feb 10, 2025
1 parent 41af01f commit 3c37450
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/main/java/com/esaulpaugh/headlong/abi/ABIJSON.java
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,10 @@ public static <T extends ABIObject> List<T> parseElements(int flags, String arra
}

/**
* Reads and parses the value of the key "abi" as a contract ABI json array.
* Reads and parses the value of the key "abi" as a contract ABI JSON array.
*
* @param flags {@link ABIType#FLAGS_NONE} (recommended) or {@link ABIType#FLAG_LEGACY_DECODE}
* @param objectJson the json object containing the "abi" field
* @param objectJson the JSON object containing the "abi" field
* @param types the types to allow in the returned {@link List}
* @return the list of ABI objects
* @param <T> the element type
Expand All @@ -129,8 +129,8 @@ public static <T extends ABIObject> List<T> parseABIField(int flags, String obje
/**
* Returns a minified version of the argument, optimized for parsing by this class. Accepts JSON array or JSON object.
*
* @param json array or object json
* @return optimized json
* @param json Contract ABI JSON array or Function/Event/ContractError JSON object
* @return optimized JSON
*/
public static String optimize(String json) {
try (final JsonReader reader = reader(json)) {
Expand Down Expand Up @@ -393,7 +393,7 @@ static <T extends ABIObject> T tryParseStreaming(JsonReader reader, Set<TypeEnum
case TYPE:
t = TypeEnum.parse(reader.nextString());
if (!types.contains(t)) {
// skip this json object. for best performance, "type" should be declared first
// skip this JSON object. for best performance, "type" should be declared first
while (reader.peek() != JsonToken.END_OBJECT) {
reader.skipValue();
}
Expand Down

0 comments on commit 3c37450

Please sign in to comment.