public class MDBServiceImpl extends loci.common.services.AbstractService implements MDBService
MDBService
for parsing MDB database files.Modifier and Type | Field and Description |
---|---|
private java.util.Vector<mdbtools.libmdb.Holder> |
boundValues |
private mdbtools.libmdb.MdbHandle |
mdb |
Constructor and Description |
---|
MDBServiceImpl()
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close the currently initialized file.
|
private boolean |
fetchRow(mdbtools.libmdb.MdbTableDef table)
Fetches the next row from the table, ignoring potential parsing exceptions.
|
void |
initialize(java.lang.String filename)
Prepare the given .mdb file for reading.
|
java.util.Vector<java.util.Vector<java.lang.String[]>> |
parseDatabase()
Read all tables from a pre-initialized .mdb files.
|
private mdbtools.libmdb.MdbHandle mdb
private java.util.Vector<mdbtools.libmdb.Holder> boundValues
public void initialize(java.lang.String filename) throws java.io.IOException
MDBService
MDBService.parseDatabase()
.initialize
in interface MDBService
java.io.IOException
- if a problem occurs when opening the filepublic java.util.Vector<java.util.Vector<java.lang.String[]>> parseDatabase() throws java.io.IOException
MDBService
MDBService.initialize(String)
must be called before calling parseDatabase().parseDatabase
in interface MDBService
java.io.IOException
- if there is a problem reading the table datapublic void close()
MDBService
close
in interface MDBService
private boolean fetchRow(mdbtools.libmdb.MdbTableDef table)
table
- Table to fetch the next available row from.true
if there are further rows to fetch.
false
if there are no further rows to fetch or an exception
is thrown while parsing the row.Copyright © 2020 Open Microscopy Environment