Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| MaltParser 1.6
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.maltparser.core.syntaxgraph.writer
Interface SyntaxGraphWriter

All Known Implementing Classes:
  BracketWriter, NegraWriter, TabWriter, TigerXMLWriter

    public interface SyntaxGraphWriter

Author:
  Johan Hall

Method Summary
`void` | `close()` Closes the file or the output stream.
`DataFormatInstance` | `getDataFormatInstance()` Returns the output data format instance
`String` | `getOptions()` Returns a string representation of the writer specific options.
`void` | `open(OutputStream os, String charsetName)` Opens an output stream
`void` | `open(String fileName, String charsetName)` Opens a file for writing
`void` | `setDataFormatInstance(DataFormatInstance dataFormatInstance)` Sets the output data format instance
`void` | `setOptions(String optionString)` Sets the writer specific options.
`void` | `writeEpilog()` Writes the end of the file
`void` | `writeProlog()` Cause the syntax graph writer to write the beginning of the file (such as header information)
`void` | `writeSentence(TokenStructure syntaxGraph)` Writes a sentence (token structure, dependency structure or/and phrase structure)

Method Detail

### open

    void open(String fileName,
              String charsetName)
              throws MaltChainedException

  Opens a file for writing

  Parameters:
    `fileName` - the file name of the file
    `charsetName` - the name of the character encoding set
  Throws:
    `MaltChainedException`

### open

    void open(OutputStream os,
              String charsetName)
              throws MaltChainedException

  Opens an output stream

  Parameters:
    `os` - an output stream
    `charsetName` - the name of the character encoding set
  Throws:
    `MaltChainedException`

### writeProlog

    void writeProlog()
                     throws MaltChainedException

  Cause the syntax graph writer to write the beginning of the file (such as header information)

  Throws:
    `MaltChainedException`

### writeSentence

    void writeSentence(TokenStructure syntaxGraph)
                       throws MaltChainedException

  Writes a sentence (token structure, dependency structure or/and phrase structure)

  Parameters:
    `syntaxGraph` - a syntax graph (token structure, dependency structure or/and phrase structure)
  Throws:
    `MaltChainedException`

### writeEpilog

    void writeEpilog()
                     throws MaltChainedException

  Writes the end of the file

  Throws:
    `MaltChainedException`

### getDataFormatInstance

    DataFormatInstance getDataFormatInstance()

  Returns the output data format instance

  Returns:
    the output data format instance

### setDataFormatInstance

    void setDataFormatInstance(DataFormatInstance dataFormatInstance)

  Sets the output data format instance

  Parameters:
    `dataFormatInstance` - an output data format instance

### getOptions

    String getOptions()

  Returns a string representation of the writer specific options.

  Returns:
    a string representation of the writer specific options.

### setOptions

    void setOptions(String optionString)
                    throws MaltChainedException

  Sets the writer specific options.

  Parameters:
    `optionString` - a string representation of the writer specific options
  Throws:
    `MaltChainedException`

### close

    void close()
               throws MaltChainedException

  Closes the file or the output stream.

  Throws:
    `MaltChainedException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| MaltParser 1.6
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2007-2011 Johan Hall, Jens Nilsson and Joakim Nivre.