public class SimpleBoundaryScanner extends Object implements BoundaryScanner
Modifier and Type | Field and Description |
---|---|
protected Set<Character> |
boundaryChars |
static Character[] |
DEFAULT_BOUNDARY_CHARS |
static int |
DEFAULT_MAX_SCAN |
protected int |
maxScan |
Constructor and Description |
---|
SimpleBoundaryScanner() |
SimpleBoundaryScanner(Character[] boundaryChars) |
SimpleBoundaryScanner(int maxScan) |
SimpleBoundaryScanner(int maxScan,
Character[] boundaryChars) |
SimpleBoundaryScanner(int maxScan,
Set<Character> boundaryChars) |
Modifier and Type | Method and Description |
---|---|
int |
findEndOffset(StringBuilder buffer,
int start)
Scan forward to find start offset.
|
int |
findStartOffset(StringBuilder buffer,
int start)
Scan backward to find end offset.
|
public static final int DEFAULT_MAX_SCAN
public static final Character[] DEFAULT_BOUNDARY_CHARS
protected int maxScan
public SimpleBoundaryScanner()
public SimpleBoundaryScanner(int maxScan)
public SimpleBoundaryScanner(Character[] boundaryChars)
public SimpleBoundaryScanner(int maxScan, Character[] boundaryChars)
public int findStartOffset(StringBuilder buffer, int start)
BoundaryScanner
findStartOffset
in interface BoundaryScanner
buffer
- scanned objectstart
- start offset to beginpublic int findEndOffset(StringBuilder buffer, int start)
BoundaryScanner
findEndOffset
in interface BoundaryScanner
buffer
- scanned objectstart
- start offset to beginCopyright © 2000-2017 Apache Software Foundation. All Rights Reserved.