k3d::table Class Reference

#include <table.h>

List of all members.

Public Types

typedef std::vector< const
table * > 
table_collection

Public Member Functions

template<typename ArrayT >
ArrayT & create (const string_t &Name)
 Creates a new array with given name and type, inserting it into the table and returning a reference to the result.
template<typename ArrayT >
ArrayT & create (const string_t &Name, ArrayT *Array)
 Inserts a new array into the table with the given name, returning a reference to the result.
const arraylookup (const string_t &Name) const
 Returns an existing array with the given name, or NULL if no matching array exists.
template<typename ArrayT >
const ArrayT * lookup (const string_t &Name) const
 Returns an existing array with the given name and type, or NULL if no matching array exists.
arraywritable (const string_t &Name)
 Returns an existing array with the given name, or NULL if no matching array exists.
template<typename ArrayT >
ArrayT * writable (const string_t &Name)
 Returns an existing array with the given name and type, or NULL if no matching array exists.
table clone_types () const
 Returns an table containing empty arrays with the same name and type as the originals.
table clone () const
 Returns an table containing deep copies of all the original arrays.
table clone (const uint_t Begin, const uint_t End) const
 Returns an table containing copies of a half-open range of all the original arrays.
void difference (const table &Other, difference::accumulator &Result) const
 Returns the difference between two tables, using the imprecise semantics of difference().
uint_t column_count () const
 Returns the number of columns in the table.
uint_t row_count () const
 Returns the number of rows in the table.
void set_row_count (const uint_t NewSize)
 Sets the number of rows in the table (i.e: resizes every column array).

Static Public Member Functions

static table clone_types (const table_collection &AttributeArrays)

Private Types

typedef std::map< string_t,
pipeline_data< array > > 
base

Private Member Functions

uint_t size () const

Detailed Description

Defines a heterogeneous collection of named, shared arrays of equal length. Note that the length of every array in the collection must remain equal at all times. For a concrete list of the datatypes that can be stored using k3d::table, see k3d::named_array_types.


Member Typedef Documentation

typedef std::map<string_t, pipeline_data<array> > k3d::table::base [private]
typedef std::vector<const table*> k3d::table::table_collection

Member Function Documentation

table k3d::table::clone ( const uint_t  Begin,
const uint_t  End 
) const

Returns an table containing copies of a half-open range of all the original arrays.

References modifier::result.

table k3d::table::clone (  )  const

Returns an table containing deep copies of all the original arrays.

References modifier::result.

Referenced by module::nurbs::curves_to_patch().

table k3d::table::clone_types ( const table_collection AttributeArrays  )  [static]

References modifier::result.

table k3d::table::clone_types (  )  const
uint_t k3d::table::column_count (  )  const

Returns the number of columns in the table.

References size().

Referenced by k3d::mesh::delete_points(), difference(), k3d::table_copier::implementation::implementation(), and k3d::require_valid_table().

template<typename ArrayT >
ArrayT& k3d::table::create ( const string_t Name,
ArrayT *  Array 
) [inline]

Inserts a new array into the table with the given name, returning a reference to the result.

Note:
: An existing array with the same name will be replaced by the new array.
template<typename ArrayT >
ArrayT& k3d::table::create ( const string_t Name  )  [inline]

Creates a new array with given name and type, inserting it into the table and returning a reference to the result.

Note:
: An existing array with the same name will be replaced by the new array.

Referenced by module::test::add_point_attributes::on_update_mesh(), module::test::add_index_attributes::on_update_mesh(), module::test::add_color_attributes::on_update_mesh(), module::test::add_color_attribute::on_update_mesh(), k3d::python::table_array_factory::operator()(), and k3d::python::table_array_factory::table_array_factory().

void k3d::table::difference ( const table Other,
difference::accumulator Result 
) const

Returns the difference between two tables, using the imprecise semantics of difference().

References angle_axis::a, column_count(), and k3d::difference::accumulator::exact.

Referenced by k3d::difference::test().

template<typename ArrayT >
const ArrayT* k3d::table::lookup ( const string_t Name  )  const [inline]

Returns an existing array with the given name and type, or NULL if no matching array exists.

References lookup().

const array * k3d::table::lookup ( const string_t Name  )  const
uint_t k3d::table::row_count (  )  const
void k3d::table::set_row_count ( const uint_t  NewSize  ) 
uint_t k3d::table::size (  )  const [private]

Referenced by column_count().

template<typename ArrayT >
ArrayT* k3d::table::writable ( const string_t Name  )  [inline]

Returns an existing array with the given name and type, or NULL if no matching array exists.

References writable().

array * k3d::table::writable ( const string_t Name  ) 

Returns an existing array with the given name, or NULL if no matching array exists.

References modifier::result.

Referenced by module::mesh_attributes::set_material::on_update_mesh(), k3d::require_array(), and writable().


The documentation for this class was generated from the following files:

Generated on Mon Mar 21 07:42:12 2011 for K-3D by doxygen 1.6.3