[][src]Trait raystack::HaystackRest

pub trait HaystackRest {
    fn about(&self) -> Result<Grid, Error>;
fn formats(&self) -> Result<Grid, Error>;
fn his_read(&self, id: &Ref, range: &HisReadRange) -> Result<Grid, Error>;
fn his_write_bool(
        &self,
        id: &Ref,
        his_data: &[(DateTime<Tz>, bool)]
    ) -> Result<Grid, Error>;
fn his_write_str(
        &self,
        id: &Ref,
        his_data: &[(DateTime<Tz>, String)]
    ) -> Result<Grid, Error>;
fn his_write_num(
        &self,
        id: &Ref,
        his_data: &[(DateTime<Tz>, f64)],
        unit: &str
    ) -> Result<Grid, Error>;
fn nav(&self, nav_id: Option<&str>) -> Result<Grid, Error>;
fn ops(&self) -> Result<Grid, Error>;
fn read(&self, filter: &str, limit: Option<u64>) -> Result<Grid, Error>;
fn read_by_ids(&self, ids: &[Ref]) -> Result<Grid, Error>; }

Provides functions which correspond to some Haystack REST API operations.

Required methods

fn about(&self) -> Result<Grid, Error>

Returns a grid containing basic server information.

fn formats(&self) -> Result<Grid, Error>

Returns a grid describing what MIME types are available.

fn his_read(&self, id: &Ref, range: &HisReadRange) -> Result<Grid, Error>

Returns a grid of history data for a single point.

fn his_write_bool(
    &self,
    id: &Ref,
    his_data: &[(DateTime<Tz>, bool)]
) -> Result<Grid, Error>

Writes boolean values to a single point.

fn his_write_str(
    &self,
    id: &Ref,
    his_data: &[(DateTime<Tz>, String)]
) -> Result<Grid, Error>

Writes string values to a single point.

fn his_write_num(
    &self,
    id: &Ref,
    his_data: &[(DateTime<Tz>, f64)],
    unit: &str
) -> Result<Grid, Error>

Writes numeric values to a single point. unit must be a valid Haystack unit literal, such as L/s or celsius.

fn nav(&self, nav_id: Option<&str>) -> Result<Grid, Error>

The Haystack nav operation.

fn ops(&self) -> Result<Grid, Error>

Returns a grid containing the operations available on the server.

fn read(&self, filter: &str, limit: Option<u64>) -> Result<Grid, Error>

Returns a grid containing the records matching the given Axon filter string.

fn read_by_ids(&self, ids: &[Ref]) -> Result<Grid, Error>

Returns a grid containing the records matching the given id Refs.

Loading content...

Implementors

impl HaystackRest for SkySparkClient[src]

Loading content...