Top Description Fields Constructors Methods
com.sun.tools.jxc

public final Class NGCCRuntimeEx

extends NGCCRuntime
Class Inheritance
Imports
java.io.File, java.util.ArrayList, .List, java.util.regex.Pattern, com.sun.tools.jxc.gen.config.NGCCRuntime, org.xml.sax.ErrorHandler, .SAXException, .SAXParseException

Controls the validating and converting of values obtained from the config file.
Author
Bhakti Mehta ([email protected])

Field Summary

Modifier and TypeField and Description
private final ErrorHandler
errorHandler

All the errors shall be sent to this object.

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private String
convertToRegex(String pattern)

This will tokenize the pattern and convert it into a regular expression

public File

Returns:

The file representation of the path name
getBaseDir
(String
The baseDir attribute passed by the user in the xml config file as a path
baseDir
)

This will check if the baseDir provided by the user in the config file exists.

public List<Pattern>

Returns:

A list of regular expression patterns Pattern
getExcludePatterns
(List<String>
The exclude list specified by the user
excludeContent
)

This takes the exclude list provided by the user in the config file It converts the user values to Pattern

public List<Pattern>

Returns:

A list of regular expression patterns Pattern
getIncludePatterns
(List<String>
The include list specified by the user
includeContent
)

This takes the include list provided by the user in the config file It converts the user values to Pattern

protected void
Inherited from com.sun.tools.jxc.gen.config.NGCCRuntime:
charactersconsumeAttributeendDocumentendElementendPrefixMappinggetAttributeIndexgetCurrentAttributesgetLocatorignorableWhitespaceonEnterElementConsumedonLeaveElementConsumedprocessingInstructionprocessListredirectSubtreereplaceresetresolveNamespacePrefixsendEnterAttributesendEnterElementsendLeaveAttributesendLeaveElementsendTextsetDocumentLocatorsetRootHandlerskippedEntitystartDocumentstartElementstartPrefixMappingtracetraceln

Field Detail

errorHandlerback to summary
private final ErrorHandler errorHandler

All the errors shall be sent to this object.

Constructor Detail

NGCCRuntimeExback to summary
public NGCCRuntimeEx(ErrorHandler errorHandler)

Method Detail

convertToRegexback to summary
private String convertToRegex(String pattern)

This will tokenize the pattern and convert it into a regular expression

getBaseDirback to summary
public File getBaseDir(String baseDir) throws SAXException

This will check if the baseDir provided by the user in the config file exists. If not it throws an error

Parameters
baseDir:String

The baseDir attribute passed by the user in the xml config file as a path

Returns:File

The file representation of the path name

Exceptions
SAXException:
if provided basedir does not exist
getExcludePatternsback to summary
public List<Pattern> getExcludePatterns(List<String> excludeContent)

This takes the exclude list provided by the user in the config file It converts the user values to Pattern

Parameters
excludeContent:List<String>

The exclude list specified by the user

Returns:List<Pattern>

A list of regular expression patterns Pattern

getIncludePatternsback to summary
public List<Pattern> getIncludePatterns(List<String> includeContent)

This takes the include list provided by the user in the config file It converts the user values to Pattern

Parameters
includeContent:List<String>

The include list specified by the user

Returns:List<Pattern>

A list of regular expression patterns Pattern

unexpectedXback to summary
protected void unexpectedX(String token) throws SAXException

Overrides com.sun.tools.jxc.gen.config.NGCCRuntime.unexpectedX.

Annotations
@Override