[][src]Struct wof::sqlite::SQLite

pub struct SQLite { /* fields omitted */ }

SQLite structure, own a connection to the database with options.

Methods

impl SQLite[src]

pub fn new<P: AsRef<Path>>(path: P, opts: SQLiteOpts) -> Result<Self, String>[src]

Create a connection to a database, the parent folder should exists.

pub fn create_tables(&self) -> Result<(), String>[src]

Create all tables, indexes and configure the database.

pub fn add_file<P: AsRef<Path>>(&self, path: P) -> Result<(), String>[src]

Add a file to the database, the file must be a WOF GeoJSON.

pub fn add_string(&self, buf: String) -> Result<(), String>[src]

Add the string content to the database, it must be a WOF GeoJSON.

pub fn add(&self, document: WOFGeoJSON) -> Result<(), String>[src]

Add a WOFGeoJSON document to the database. The SQLiteOpts is used here and it will define in which table the document should be added.

Trait Implementations

impl Debug for SQLite[src]

Auto Trait Implementations

impl !RefUnwindSafe for SQLite

impl Send for SQLite

impl !Sync for SQLite

impl Unpin for SQLite

impl UnwindSafe for SQLite

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.