Skip to content

Commit

Permalink
Add javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
wanglingsong committed Aug 11, 2017
1 parent ca67375 commit 26b3808
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
24 changes: 24 additions & 0 deletions jsurfer-core/src/main/java/org/jsfr/json/JsonSurfer.java
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,8 @@ public void onValue(Object value, ParsingContext context) {
}

/**
* Start surfing
*
* @param json json
* @param configuration SurfingConfiguration that holds JsonPath binding
*/
Expand All @@ -159,6 +161,8 @@ public void surf(String json, SurfingConfiguration configuration) {
}

/**
* Start surfing
*
* @param json Json source
* @param configuration SurfingConfiguration that holds JsonPath binding
*/
Expand All @@ -167,16 +171,36 @@ public void surf(Reader json, SurfingConfiguration configuration) {
jsonParserAdapter.parse(json, new SurfingContext(configuration));
}

/**
* Create resumable parser
*
* @param json Json source
* @param configuration SurfingConfiguration
* @return Resumable parser
*/
public ResumableParser createResumableParser(String json, SurfingConfiguration configuration) {
ensureSetting(configuration);
return jsonParserAdapter.createResumableParser(json, new SurfingContext(configuration));
}

/**
* Create resumable parser
*
* @param json Json source
* @param configuration SurfingConfiguration
* @return Resumable parser
*/
public ResumableParser createResumableParser(Reader json, SurfingConfiguration configuration) {
ensureSetting(configuration);
return jsonParserAdapter.createResumableParser(json, new SurfingContext(configuration));
}

/**
* Create non-blocking parser
*
* @param configuration
* @return
*/
public NonBlockingParser createNonBlockingParser(SurfingConfiguration configuration) {
ensureSetting(configuration);
return jsonParserAdapter.createNonBlockingParser(new SurfingContext(configuration));
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package org.jsfr.json;

/**
* Resumable Parser
* A parser can be paused and resumed
*/
public interface ResumableParser {

Expand Down

0 comments on commit 26b3808

Please sign in to comment.