public class Master extends Object implements AutoCloseable
| Constructor and Description |
|---|
Master(InputStream in)
Initializes the master file reader.
|
Master(InputStream in,
Name origin)
Initializes the master file reader.
|
Master(InputStream in,
Name origin,
long ttl)
Initializes the master file reader.
|
Master(String filename)
Initializes the master file reader and opens the specified master file.
|
Master(String filename,
Name origin)
Initializes the master file reader and opens the specified master file.
|
Master(String filename,
Name origin,
long ttl)
Initializes the master file reader and opens the specified master file.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
disableIncludes()
Disable processing of $INCLUDE directives.
|
void |
disableIncludes(boolean strict)
Disable processing of $INCLUDE directives.
|
void |
expandGenerate(boolean wantExpand)
Specifies whether $GENERATE statements should be expanded.
|
Iterator<Generator> |
generators()
Returns an iterator over the generators specified in the master file; that is, the parsed
contents of $GENERATE statements.
|
Record |
nextRecord()
Returns the next record in the master file.
|
public Master(String filename, Name origin, long ttl) throws IOException
filename - The master file.origin - The initial origin to append to relative names.ttl - The initial default TTL.IOException - The master file could not be opened.public Master(String filename, Name origin) throws IOException
filename - The master file.origin - The initial origin to append to relative names.IOException - The master file could not be opened.public Master(String filename) throws IOException
filename - The master file.IOException - The master file could not be opened.public Master(InputStream in, Name origin, long ttl)
in - The input stream containing a master file.origin - The initial origin to append to relative names.ttl - The initial default TTL.public Master(InputStream in, Name origin)
in - The input stream containing a master file.origin - The initial origin to append to relative names.public Master(InputStream in)
in - The input stream containing a master file.public Record nextRecord() throws IOException
IOException - The master file could not be read, or was syntactically invalid.public void disableIncludes()
public void disableIncludes(boolean strict)
strict - If true, an exception will be thrown if $INCLUDE is encountered.public void expandGenerate(boolean wantExpand)
generators. This must be
called before a $GENERATE statement is seen during iteration to have an effect.public Iterator<Generator> generators()
Generatorpublic void close()
close in interface AutoCloseableCopyright © 2021 dnsjava.org. All rights reserved.