Struct agnes::view::DataView
[−]
[src]
pub struct DataView { /* fields omitted */ }
A 'view' into a data store. The primary struct for viewing and manipulating data.
Methods
impl DataView
[src]
pub fn v<L: IntoFieldList>(&self, s: L) -> DataView
[src]
Generate a new subview of this DataView.
pub fn subview<L: IntoFieldList>(&self, s: L) -> Result<DataView>
[src]
Generate a new subview of this DataView, generating an error if a specified field does not exist.
pub fn nrows(&self) -> usize
[src]
Number of rows in this data view
pub fn nfields(&self) -> usize
[src]
Number of fields in this data view
pub fn fieldnames(&self) -> Vec<&String>
[src]
Field names in this data view
pub fn rename<T, U>(&mut self, orig: T, new: U) -> Result<()> where
T: Into<FieldIdent>,
U: Into<FieldIdent>,
[src]
T: Into<FieldIdent>,
U: Into<FieldIdent>,
Rename a field of this DataView.
pub fn merge(&self, other: &DataView) -> Result<DataView>
[src]
Merge this DataView
with another DataView
object, creating a new DataView
with the
same number of rows and all the fields from both source DataView
objects.
pub fn join(&self, other: &DataView, join: Join) -> Result<DataStore>
[src]
Combine two DataView
objects using specified join, creating a new DataStore
object with
a subset of records from the two source DataView
s according to the join parameters.
Note that since this is creating a new DataStore
object, it will be allocated new data to
store the contents of the joined DataView
s.
impl DataView
[src]
pub fn as_fieldview(&self) -> Option<FieldView>
[src]
Create a FieldView
object from a DataView
object, if possible. Typically, use this on
DataView
objects with only a single field; however, if the DataView
object has multiple
fields, the first one will be used for this FieldView
. Returns None
if the DataView
has no fields (is empty).
Trait Implementations
impl Debug for DataView
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Clone for DataView
[src]
fn clone(&self) -> DataView
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Default for DataView
[src]
impl From<DataStore> for DataView
[src]
impl Display for DataView
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
[src]
Formats the value using the given formatter. Read more