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

## com.bbn.openmap.dataAccess.shape.output
Class DbfOutputStream

    java.lang.Object
      com.bbn.openmap.dataAccess.shape.output.DbfOutputStream

public class DbfOutputStream
extends java.lang.Object

Writes date in a DbfTableModel to a file, conforming to the DBF III file format specification

Author:
  Doug Van Auken

Constructor Summary
`DbfOutputStream(java.io.OutputStream os)` Creates a DbfOutputStream

Method Summary
`short` | `calcHeaderLength(DbfTableModel model)` Calculates the length of the header in terms of bytes
`short` | `calcRecordLength(DbfTableModel model)` Calculates the length of the record by aggregating the length of each field
`void` | `close()`
`protected void` | `writeDbfFileRecords(DbfFile model)`
`void` | `writeModel(DbfTableModel model)` Writes the model out on the stream.
`void` | `writeRecords(DbfTableModel model)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### DbfOutputStream

    public DbfOutputStream(java.io.OutputStream os)

  Creates a DbfOutputStream

Method Detail

### writeModel

    public void writeModel(DbfTableModel model)
                    throws java.io.IOException

  Writes the model out on the stream. The stream is closed automatically after the write.

  Parameters:
    `model` - the tablemodel to write
  Throws:
    `java.io.IOException`

### calcRecordLength

    public short calcRecordLength(DbfTableModel model)

  Calculates the length of the record by aggregating the length of each field

  Parameters:
    `model` - The DbfTableModel for which to calculate the record length
  Returns:
    The length of a record

### calcHeaderLength

    public short calcHeaderLength(DbfTableModel model)

  Calculates the length of the header in terms of bytes

  Parameters:
    `model` - The DbfTableModel for which to calculate header length
  Returns:
    The header length

### writeDbfFileRecords

    protected void writeDbfFileRecords(DbfFile model)
                                throws java.io.IOException

  Throws:
    `java.io.IOException`

### writeRecords

    public void writeRecords(DbfTableModel model)
                      throws java.io.IOException

  Throws:
    `java.io.IOException`

### close

    public void close()
               throws java.io.IOException

  Throws:
    `java.io.IOException`

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

Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details