public abstract class GPEParser extends java.lang.Object implements IGPEParser
Constructor and Description |
---|
GPEParser()
All the GPE parser must implement an empty constructor
|
Modifier and Type | Method and Description |
---|---|
abstract boolean |
accept(java.io.File file)
Return if the driver can open the file
|
abstract boolean |
accept(java.net.URI uri)
Return if the driver can open the file
|
IGPEContentHandlerInmGeom |
getContentHandler() |
abstract java.lang.String |
getDescription() |
IGPEErrorHandler |
getErrorHandler() |
abstract java.lang.String |
getFormat()
Return the format that the driver
is able to read
|
GPEManager |
getGpeManager() |
protected java.io.InputStream |
getInputStream() |
java.net.URI |
getMainFile() |
abstract java.lang.String |
getName() |
void |
parse(IGPEContentHandlerInmGeom contents,
IGPEErrorHandler errors,
java.io.InputStream is)
Method to parse an InputStream.
|
void |
parse(IGPEContentHandlerInmGeom contents,
IGPEErrorHandler errors,
java.net.URI uri)
Method to parse a file.
|
protected abstract void |
parseStream()
Parses the file from an input stream
|
protected abstract void |
parseURI()
Parses the file from a URI
|
void |
setContentHandler(IGPEContentHandlerInmGeom contentHandler) |
void |
setErrorHandler(IGPEErrorHandler errorHandler) |
protected void |
setInputStream(java.io.InputStream is)
Deprecated.
to avoid temporal coupling
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getProjection
public GPEParser()
public void parse(IGPEContentHandlerInmGeom contents, IGPEErrorHandler errors, java.net.URI uri)
parse
in interface IGPEParser
contents
- Application ContentHandlererrors
- Application ErrorsHandleruri
- File to openjava.lang.Exception
protected abstract void parseURI()
public void parse(IGPEContentHandlerInmGeom contents, IGPEErrorHandler errors, java.io.InputStream is)
parse
in interface IGPEParser
contents
- Application ContentHandlererrors
- Application ErrorsHandleris
- The input streamjava.lang.Exception
protected abstract void parseStream()
public abstract boolean accept(java.net.URI uri)
accept
in interface IGPEParser
uri
- File to openpublic abstract boolean accept(java.io.File file)
uri
- File to openpublic abstract java.lang.String getFormat()
getFormat
in interface IGPEParser
public IGPEContentHandlerInmGeom getContentHandler()
getContentHandler
in interface IGPEParser
public IGPEErrorHandler getErrorHandler()
getErrorHandler
in interface IGPEParser
public java.net.URI getMainFile()
getMainFile
in interface IGPEParser
public abstract java.lang.String getDescription()
getDescription
in interface IGPEParser
public abstract java.lang.String getName()
getName
in interface IGPEParser
protected java.io.InputStream getInputStream()
protected void setInputStream(java.io.InputStream is)
is
- the is to setpublic void setErrorHandler(IGPEErrorHandler errorHandler)
setErrorHandler
in interface IGPEParser
errorHandler
- the errorHandler to setpublic void setContentHandler(IGPEContentHandlerInmGeom contentHandler)
setContentHandler
in interface IGPEParser
contentHandler
- the contentHandler to setpublic GPEManager getGpeManager()