gnu.javax.swing.text.html.parser.support.low

Class Constants

Known Direct Subclasses:
ReaderTokenizer

public class Constants
extends Object

The parser constants and operations, directly related to the parser constants.

Field Summary

static int
AP
Quoting sign.
static int
BEGIN
Start of HTML token.
static pattern
COMMENT_END
Comment closing sequence
static pattern
COMMENT_OPEN
Comment opening sequence.
static pattern
COMMENT_TRIPLEDASH_END
Special case ---> (also is treated as end of comment).
static int
DOUBLE_DASH
Double dash (--)
static int
END
End of HTML token.
static int
ENTITY
Named or numeric entity,
static int
ENTITY_NAMED
Named entity.
static int
ENTITY_NUMERIC
Numeric entity.
static int
EOF
End of file.
static int
EQ
Equals sign.
static int
EXCLAMATION
Exclamation (indicates SGML or comment).
static int
NUMTOKEN
Sequence of valid name characters (can start from digit).
static int
OTHER
All other tokens.
static int
QUOT
Quoting sign.
static int
SCRIPT
The SCRIPT tag (needs special handling).
static pattern
SCRIPT_CLOSE
SCRIPT element closing pattern.
static pattern
SCRIPT_OPEN
SCRIPT element heading pattern.
static pattern
SGML
SGML element heading pattern.
static int
SLASH
Slash (indicates closing tag).
static int
STYLE
The STYLE tag (needs special handling).
static pattern
STYLE_CLOSE
STYLE element closing pattern.
static pattern
STYLE_OPEN
STYLE element heading pattern.
static pattern
TAG
Ordinary HTML tag heading pattern.
static pattern
TAG_CLOSE
Ordinary HTML tag closing pattern.
static int
WS
HTML whitespace.
static BitSet
bDIGIT
Digits.
static BitSet
bLETTER
All letters, used in HTML names.
static BitSet
bLINEBREAK
Both line breaks.
static BitSet
bNAME
Valid name characters.
static BitSet
bQUOTING
Both quoting characters.
static BitSet
bSINGLE_CHAR_TOKEN
All single char tokens.
static BitSet
bSPECIAL
Non letters and non numbers, allowed in HTML names.
static BitSet
bWHITESPACE
All whitespace.

Method Summary

Token
endMatches(Buffer b)
Verifies if one of the tokens matches the end of string buffer.

Methods inherited from class java.lang.Object

clone, equals, extends Object> getClass, finalize, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Details

AP

public static final int AP
Quoting sign.
Field Value:
92

BEGIN

public static final int BEGIN
Start of HTML token.
Field Value:
60

COMMENT_END

public static final pattern COMMENT_END
Comment closing sequence

COMMENT_OPEN

public static final pattern COMMENT_OPEN
Comment opening sequence.

COMMENT_TRIPLEDASH_END

public static final pattern COMMENT_TRIPLEDASH_END
Special case ---> (also is treated as end of comment).

DOUBLE_DASH

public static final int DOUBLE_DASH
Double dash (--)
Field Value:
1000

END

public static final int END
End of HTML token.
Field Value:
62

ENTITY

public static final int ENTITY
Named or numeric entity,
Field Value:
1004

ENTITY_NAMED

public static final int ENTITY_NAMED
Named entity.
Field Value:
1

ENTITY_NUMERIC

public static final int ENTITY_NUMERIC
Numeric entity.
Field Value:
2

EOF

public static final int EOF
End of file.
Field Value:
3

EQ

public static final int EQ
Equals sign.
Field Value:
61

EXCLAMATION

public static final int EXCLAMATION
Exclamation (indicates SGML or comment).
Field Value:
33

NUMTOKEN

public static final int NUMTOKEN
Sequence of valid name characters (can start from digit).
Field Value:
1005

OTHER

public static final int OTHER
All other tokens.
Field Value:
1999

QUOT

public static final int QUOT
Quoting sign.
Field Value:
34

SCRIPT

public static final int SCRIPT
The SCRIPT tag (needs special handling).
Field Value:
1002

SCRIPT_CLOSE

public static final pattern SCRIPT_CLOSE
SCRIPT element closing pattern.

SCRIPT_OPEN

public static final pattern SCRIPT_OPEN
SCRIPT element heading pattern.

SGML

public static final pattern SGML
SGML element heading pattern.

SLASH

public static final int SLASH
Slash (indicates closing tag).
Field Value:
47

STYLE

public static final int STYLE
The STYLE tag (needs special handling).
Field Value:
1001

STYLE_CLOSE

public static final pattern STYLE_CLOSE
STYLE element closing pattern.

STYLE_OPEN

public static final pattern STYLE_OPEN
STYLE element heading pattern.

TAG

public static final pattern TAG
Ordinary HTML tag heading pattern.

TAG_CLOSE

public static final pattern TAG_CLOSE
Ordinary HTML tag closing pattern.

WS

public static final int WS
HTML whitespace.
Field Value:
1003

bDIGIT

public static final BitSet bDIGIT
Digits.

bLETTER

public static final BitSet bLETTER
All letters, used in HTML names.

bLINEBREAK

public static final BitSet bLINEBREAK
Both line breaks.

bNAME

public static final BitSet bNAME
Valid name characters.

bQUOTING

public static final BitSet bQUOTING
Both quoting characters.

bSINGLE_CHAR_TOKEN

public static final BitSet bSINGLE_CHAR_TOKEN
All single char tokens.

bSPECIAL

public static final BitSet bSPECIAL
Non letters and non numbers, allowed in HTML names.

bWHITESPACE

public static final BitSet bWHITESPACE
All whitespace.

Method Details

endMatches

public Token endMatches(Buffer b)
Verifies if one of the tokens matches the end of string buffer. The last character in the string buffer is the "future character", some tokens needs to verify it the token does not continue "towards the future". If the token matches, it matches till "pre-last" character in the buffer.
Parameters:
b -
Returns:

Constants.java -- Copyright (C) 2005 Free Software Foundation, Inc. This file is part of GNU Classpath. GNU Classpath is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2, or (at your option) any later version. GNU Classpath is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with GNU Classpath; see the file COPYING. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Linking this library statically or dynamically with other modules is making a combined work based on this library. Thus, the terms and conditions of the GNU General Public License cover the whole combination. As a special exception, the copyright holders of this library give you permission to link this library with independent modules to produce an executable, regardless of the license terms of these independent modules, and to copy and distribute the resulting executable under terms of your choice, provided that you also meet, for each linked independent module, the terms and conditions of the license of that module. An independent module is a module which is not derived from or based on this library. If you modify this library, you may extend this exception to your version of the library, but you are not obligated to do so. If you do not wish to do so, delete this exception statement from your version.