|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectJFlex.Skeleton
public class Skeleton
This class stores the skeleton of generated scanners.
The skeleton consists of several parts that can be emitted to
a file. Usually there is a portion of generated code
(produced in class Emitter) between every two parts of skeleton code.
There is a static part (the skeleton code) and state based iterator
part to this class. The iterator part is used to emit consecutive skeleton
sections to some PrintWriter.
Emitter| Field Summary | |
|---|---|
static java.lang.String[] |
line
The skeleton |
| Constructor Summary | |
|---|---|
Skeleton(java.io.PrintWriter out)
Creates a new skeleton (iterator) instance. |
|
| Method Summary | |
|---|---|
void |
emitNext()
Emits the next part of the skeleton |
static void |
makePrivate()
Make the skeleton private. |
static void |
readDefault()
(Re)load the default skeleton. |
static void |
readSkel(java.io.BufferedReader reader)
Reads an external skeleton file from a BufferedReader. |
static void |
readSkelFile(java.io.File skeletonFile)
Reads an external skeleton file for later use with this class. |
static java.lang.String |
replace(java.lang.String a,
java.lang.String b,
java.lang.String c)
Replaces a with b in c. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static java.lang.String[] line
| Constructor Detail |
|---|
public Skeleton(java.io.PrintWriter out)
out - the writer to write the skeleton-parts to| Method Detail |
|---|
public void emitNext()
public static void makePrivate()
public static void readSkelFile(java.io.File skeletonFile)
skeletonFile - the file to read (must be != null and readable)
public static void readSkel(java.io.BufferedReader reader)
throws java.io.IOException
reader - the reader to read from (must be != null)
java.io.IOException - if an IO error occurs
GeneratorException - if the number of skeleton sections does not match
public static java.lang.String replace(java.lang.String a,
java.lang.String b,
java.lang.String c)
a - the String to be replacedb - the replacementc - the String in which to replace a by b
public static void readDefault()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||