SheafSystem  0.0.0.0
fiber_bundle::array_field_dof_map Class Reference

A contiguous tuple, contiguous fiber representation of the abstract map from section_space_schema_member ids to section dof values of homogeneous type double. More...

#include <array_field_dof_map.h>

Inheritance diagram for fiber_bundle::array_field_dof_map:
fiber_bundle::field_dof_map fiber_bundle::section_dof_map sheaf::poset_dof_map sheaf::any

Public Member Functions

virtual const std::string & class_name () const
 The name of the actual (possibly derived) class of this instance. More...
 
 array_field_dof_map ()
 Default constructor. More...
 
virtual array_field_dof_mapclone () const
 Virtual default constructor. More...
 
 array_field_dof_map (const array_field_dof_map &xother)
 Copy constructor. More...
 
virtual array_field_dof_mapcopy () const
 Virtual copy constructor. More...
 
array_field_dof_mapoperator= (const array_field_dof_map &xother)
 Assignment operator. More...
 
virtual ~array_field_dof_map ()
 Destructor. More...
 
virtual bool invariant () const
 The class invariant. More...
 
 array_field_dof_map (const sec_rep_space *xhost, void *xdofs=0, size_t xdofs_ub=0)
 Creates a dof map for a member of sec_rep_space xhost. If xdofs is non zero, it will be used for dof storage, otherwise storage will be allocated. More...
 
virtual dof_tuple_type type_id () const
 An identifer for the type of dof tuple this is. More...
 
virtual void get_dof (const scoped_index &xid, bool xis_poset_id, void *xbuf, size_t xbuf_len) const
 Copies the value of the dof referred to by the xid and xis_poset_id into the buffer of length xbuf_len bytes starting at xbuf. More...
 
virtual void put_dof (const scoped_index &xid, bool xis_poset_id, const void *xbuf, size_t xbuf_len)
 Copies the value of the dof referred to by the xid and xis_poset_id from the buffer of length xbuf_len bytes starting at xbuf. More...
 
virtual void get_dofs (const client_index *xclient_ids, int xclient_id_ct, void *xbuf, size_t xbuf_len) const
 Copies the values of the dofs referred to by the xclient_id_ct client ids in xclient_ids into the buffer of length xbuf_len bytes starting at xbuf. More...
 
virtual void put_dofs (const client_index *xclient_ids, int xclient_id_ct, const void *xbuf, size_t xbuf_len)
 Copies the values of the dofs referred to by the xclient_id_ct client ids in xclient_ids from the buffer of length xbuf_len bytes starting at xbuf into internal storage. More...
 
virtual void get_dof (const scoped_index &xbase_id, const scoped_index &xfiber_id, const scoped_index &xmult_id, bool xis_poset_id, void *xbuf, size_t xbuf_len) const
 Copies the value of the dof referred to by the ids xbase_id, xfiber_id, and xmult_id into the buffer of length xbuf_len bytes starting at xbuf. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids. More...
 
virtual void put_dof (const scoped_index &xbase_id, const scoped_index &xfiber_id, const scoped_index &xmult_id, bool xis_poset_id, const void *xbuf, size_t xbuf_len)
 Copies the value of the dof referred to by the ids in xbase_id, xfiber_id, and xmult_id from the buffer of length xbuf_len bytes starting at xbuf. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids. More...
 
virtual void get_dofs (const client_index *xclient_base_ids, int xclient_base_id_ct, const client_index *xclient_fiber_ids, int xclient_fiber_id_ct, void *xbuf, size_t xbuf_len) const
 Copies the values of the dofs referred to by the client ids in xclient_base_ids x xclient_fiber_ids into the buffer of length xbuf_len bytes starting at xbuf. More...
 
virtual void put_dofs (const client_index *xclient_base_ids, int xclient_base_id_ct, const client_index *xclient_fiber_ids, int xclient_fiber_id_ct, const void *xbuf, size_t xbuf_len)
 Copies the values of the dofs referred to by the client ids in xclient_base_ids x xclient_fiber_ids from the buffer of length xbuf_len bytes starting at xbuf. More...
 
virtual void get_discretization_dofs (const scoped_index &xdisc_id, bool xis_poset_id, void *xbuf, size_t xbuf_len) const
 Copys the dofs associated with the discretization member identified by xdisc_id into the buffer of length xbuf_len bytes starting at xbuf. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids. More...
 
virtual void put_discretization_dofs (const scoped_index &xdisc_id, bool xis_poset_id, const void *xbuf, size_t xbuf_len)
 Copys the dofs associated with the discretization member identified by xdisc_id from the buffer of length xbuf_len bytes starting at xbuf into internal storage. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids. More...
 
virtual void get_component_dofs (void *xbuf, size_t xbuf_len, const scoped_index &xcomp_id, const scoped_index *xdisc_ids=0, size_type xdisc_ids_ct=0) const
 Copys the dofs associated with the fiber component identified by xcomp_id from internal storage into buffer xbuf of length xbuf_len bytes. More...
 
virtual void put_component_dofs (const void *xbuf, size_t xbuf_len, const scoped_index &xcomp_id, const scoped_index *xdisc_ids=0, size_type xdisc_ids_ct=0)
 Copys the dofs associated with the fiber component identified by xcomp_id from buffer xbuf of length xbuf_len bytes into internal storage. More...
 
virtual void get_component_dofs (void *xbuf, size_t xbuf_len, const client_index &xcomp_id, const id_map *xcomp_client_id_map, const client_index *xdisc_ids=0, size_type xdisc_ids_ct=0, const id_map *xdisc_client_id_map=0) const
 Copys the dofs associated with the fiber component identified by xcomp_id from internal storage into buffer xbuf of length xbuf_len bytes. Xcomp_client_id_map is used to convert xcomp_id from a client id to a poset member id. More...
 
virtual void put_component_dofs (const void *xbuf, size_t xbuf_len, const client_index &xcomp_id, const id_map *xcomp_client_id_map, const client_index *xdisc_ids=0, size_type xdisc_ids_ct=0, const id_map *xdisc_client_id_map=0)
 Copys the dofs associated with the fiber component identified by xcomp_id from buffer xbuf of length xbuf_len bytes into internal storage. Xcomp_client_id_map is used to convert xcomp_id from a client id to a poset member id. More...
 
virtual void * dof_tuple ()
 The dof tuple (mutable version). More...
 
virtual const void * dof_tuple () const
 The dof tuple (const version). More...
 
virtual void get_dof_tuple (void *xbuf, size_t xbuflen) const
 Copies the entire dof tuple from internal storage into xbuf. More...
 
virtual void put_dof_tuple (const void *xbuf, size_t xbuflen)
 Copies the entire dof tuple from xbuf into internal storage. More...
 
- Public Member Functions inherited from fiber_bundle::field_dof_map
field_dof_mapoperator= (const field_dof_map &xother)
 Assignment operator. More...
 
virtual ~field_dof_map ()
 Destructor. More...
 
void get_dofs (const client_index *xclient_base_ids, int xclient_base_id_ct, const client_index *xclient_fiber_ids, int xclient_fiber_id_ct, double *xbuf, int xbuf_len) const
 Double version of get_dofs. More...
 
void put_dofs (const client_index *xclient_base_ids, int xclient_base_id_ct, const client_index *xclient_fiber_ids, int xclient_fiber_id_ct, const double *xbuf, int xbuf_len)
 Double version of put_dofs. More...
 
- Public Member Functions inherited from fiber_bundle::section_dof_map
section_dof_mapoperator= (const section_dof_map &xother)
 Assignment operator. More...
 
virtual ~section_dof_map ()
 Destructor. More...
 
virtual sec_rep_spacehost () const
 The poset which hosts member() More...
 
virtual section_space_schema_memberschema ()
 The schema on which this is allocated (mutable version). More...
 
virtual const section_space_schema_memberschema () const
 The schema on which this is allocated (const version). More...
 
virtual bool dof_in_bounds (pod_index_type xdof_id, bool xis_table_dofs) const
 True if and only if the dof asociated with id xdof_id is within the current capacity of the dofs storage. More...
 
virtual bool dof_in_bounds (pod_index_type xdisc_id, pod_index_type xfiber_id, bool xis_table_dofs) const
 True if and only if the dof asociated with discretization id xdisc_id and fiber dof id xfiber_id is within the current capacity of the dofs storage. More...
 
void get_dof (pod_index_type xdisc_id, pod_index_type xfiber_dof_id, void *xdof, size_type xdof_size)
 
void get_dof (const scoped_index &xdisc_id, const scoped_index &xfiber_dof_id, void *xdof, size_type xdof_size) const
 Copies the dof referred to by xdisc_id, xfiber_dof_id into xdof. More...
 
void get_dof (const scoped_index &xdisc_id, const scoped_index &xfiber_dof_id, void *xdof, size_type xdof_size)
 
void put_dof (const scoped_index &xdisc_id, const scoped_index &xfiber_dof_id, const void *xdof, size_type xdof_size)
 Sets the dof referred to by xdof_id to the value at xdof. More...
 
virtual bool fiber_in_bounds (pod_index_type xdisc_id, bool xis_table_dofs) const
 True if and only if the fiber asociated with discretization id xdisc_id is within the current capacity of the dofs storage. More...
 
void get_fiber (const scoped_index &xdisc_id, void *xfiber, size_type xfiber_size) const
 Sets xfiber to the fiber referred to by discretization id xdisc_id. More...
 
void put_fiber (const scoped_index &xdisc_id, const void *xfiber, size_type xfiber_size)
 Sets the fiber referred to by discretization id xdisc_id to xfiber. More...
 
virtual void force_fiber (pod_index_type xdisc_id, const void *xfiber, size_type xfiber_size)
 Sets the fiber referred to by discretization id xdisc_id to xfiber; allocates additional memory if necessary. More...
 
void force_fiber (const scoped_index &xdisc_id, const void *xfiber, size_type xfiber_size)
 Sets the fiber referred to by discretization id xdisc_id to xfiber; allocates additional memory if necessary. More...
 
void get_component (const scoped_index &xfiber_dof_id, void *xcomponent, size_type xcomponent_size) const
 Sets xcomponent to the component referred to by fiber id xfiber_dof_id. More...
 
void put_component (const scoped_index &xfiber_dof_id, const void *xcomponent, size_type xcomponent_size)
 Sets the component referred to by fiber id xfiber_dof_id to xcomponent. More...
 
virtual bool supports_xfr_opt () const
 True if this dof map type supports dof tuple transfer optimization. /. More...
 
- Public Member Functions inherited from sheaf::poset_dof_map
poset_dof_mapoperator= (const poset_dof_map &xother)
 Assignment operator. More...
 
virtual ~poset_dof_map ()
 Destructor. More...
 
virtual void init_row_dof_map (const poset_state_handle *xhost, pod_index_type xschema_mbr_id, int xschema_version)
 Initializes this as a map for row dofs in host xhost, with schema member specified by xschema_mbr_id and schema version xschema_version. More...
 
void init_row_dof_map (const poset_state_handle *xhost, const scoped_index &xschema_mbr_id, int xschema_version)
 Initializes this as a map for row dofs in host xhost, with schema member specified by xschema_mbr_id and schema version xschema_version. More...
 
bool is_initialized () const
 True if this has been initialized, that is, if the schema has been set and the dof map storage allocated. More...
 
const scoped_indexindex () const
 The index of this in host() dof tuple table. More...
 
bool is_table_dof_map () const
 True if this is a table dof map. More...
 
int dof_ct () const
 The number of dofs in this map. More...
 
primitive_value dof (pod_index_type xdof_id) const
 The dof referred to by xdof_id. More...
 
primitive_value dof (const scoped_index &xdof_id) const
 The dof referred to by xdof_id. More...
 
primitive_value dof (const std::string &xname) const
 The dof with name xname. More...
 
void put_dof (pod_index_type xdof_id, const primitive_value &xdof)
 Sets the dof referred to by xdof_id to xdof. More...
 
void put_dof (const scoped_index &xdof_id, const primitive_value &xdof)
 Sets the dof referred to by xdof_id to xdof. More...
 
void put_dof (const std::string &xname, const primitive_value &xdof)
 Sets the dof with name xname to xdof. More...
 
void get_dof (const scoped_index &xdof_id, void *xdof, size_type xdof_size) const
 Copies the dof referred to by xdof_id into xdof. More...
 
virtual void put_dof (pod_index_type xdof_id, const void *xdof, size_type xdof_size)
 Sets the dof referred to by xdof_id to the value at xdof. More...
 
void put_dof (const scoped_index &xdof_id, const void *xdof, size_type xdof_size)
 Sets the dof referred to by xdof_id to the value at xdof. More...
 
size_t dof_tuple_ub () const
 The size of the dof tuple in bytes. More...
 
void get_dof_tuple (arg_list &xargs) const
 Copies the entire dof tuple from internal storage into xargs. More...
 
void put_dof_tuple (const arg_list &xargs)
 Copies the entire dof tuple from xargs into internal storage. More...
 
void copy_dof_tuple (const poset_dof_map &xother)
 Copies the dof tuple of xother into this. More...
 
virtual void put_defaults ()
 Sets all dofs to defualt values. More...
 
unsigned int ref_ct () const
 The number of references to this map. More...
 
void inc_ref_ct ()
 Increase the number of references to this map by one;. More...
 
void dec_ref_ct ()
 Decrease the number of references to this map by one. More...
 
int version () const
 The version of the host of the schema this is defined on. More...
 
virtual const index_space_handleclient_id_space () const
 The map from library ids to clients ids for the schema this is defined on. More...
 
std::string to_string (const schema_poset_member &xschema) const
 Return schema member dof value as a string. More...
 
std::string to_string () const
 Return dof values as a formated string. More...
 
- Public Member Functions inherited from sheaf::any
virtual bool is_ancestor_of (const any *other) const
 True if other conforms to this. More...
 
bool is_same_type (const any *other) const
 True if other is the same type as this. More...
 
virtual ~any ()
 Destructor. More...
 
bool invariant_check () const
 True if invariant checking is enabled. More...
 
void enable_invariant_check () const
 Enable invariant checking. More...
 
void disable_invariant_check () const
 Disable invariant check. Intended for preventing recursive calls to invariant and for suppressing invariant checking during multi-phase initialization. More...
 
int disable_invariance_check_request_depth () const
 Number of times disable_invariant_check has been called without matching call to enable_invariant_check. More...
 

Static Public Member Functions

static const std::string & static_class_name ()
 The name of this class. More...
 
- Static Public Member Functions inherited from fiber_bundle::field_dof_map
static const std::string & static_class_name ()
 The name of this class. More...
 
- Static Public Member Functions inherited from fiber_bundle::section_dof_map
static const std::string & static_class_name ()
 The name of this class. More...
 
- Static Public Member Functions inherited from sheaf::poset_dof_map
static const std::string & static_class_name ()
 The name of this class. More...
 
static poset_dof_mapnew_dof_map (const std::string &xclass_name, dof_tuple_type xsheaf_base_class_id)
 Creates an uninitialized dof map of type xclass_name, if a prototype of that name exists, otherwise of type xsheaf_base_class_id. More...
 

Protected Member Functions

virtual void allocate_dofs ()
 Allocates dof storage. More...
 
- Protected Member Functions inherited from fiber_bundle::field_dof_map
 field_dof_map ()
 Default constructor. More...
 
 field_dof_map (const field_dof_map &xother)
 Copy constructor. More...
 
 field_dof_map (const sec_rep_space *xhost)
 Creates a map for the poset dofs of xhost. More...
 
- Protected Member Functions inherited from fiber_bundle::section_dof_map
 section_dof_map ()
 Default constructor. More...
 
 section_dof_map (const section_dof_map &xother)
 Copy constructor. More...
 
 section_dof_map (sec_rep_space *xhost, pod_index_type xbase_id, int xversion)
 Creates a map for a (possibly partial) section of xhost defined on version xversion of the base space member identified by xbase_id. More...
 
- Protected Member Functions inherited from sheaf::poset_dof_map
 poset_dof_map ()
 Default constructor;. More...
 
 poset_dof_map (const poset_dof_map &xother)
 Copy constructor. More...
 
 poset_dof_map (const poset_state_handle *xhost, bool xis_table_dof_map)
 Creates a map for the table dofs (xis_table_dofs true) or row dofs (xis_table dofs false) for use in host xhost. More...
 
 poset_dof_map (const schema_poset_member *xschema, bool xis_table_dof_map)
 Creates a map for the table dofs (xis_table_dofs true) or row dofs (xis_table dofs false) for use in host xhost. More...
 
virtual void put_host (const poset_state_handle *xhost)
 Sets host() to xhost. More...
 
void put_index (const scoped_index &xindex)
 Sets the index of the member for which this provides the dofs. More...
 
void put_dof_ct (int xdof_ct)
 Sets dof_ct() to xdof_ct. More...
 
void put_dof_tuple_ub (size_t xub)
 Sets dof_tuple_ub() to xub. More...
 
void put_ref_ct (int xref_ct)
 Sets ref_ct() to xref_ct). More...
 
- Protected Member Functions inherited from sheaf::any
 any ()
 default constructor More...
 

NEW DOF ACCESS FACET

virtual void get_dof (pod_index_type xdof_id, void *xdof, size_type xdof_size) const
 Copies the dof referred to by xdof_id into xdof. More...
 
virtual void put_dof (pod_index_type xdof_id, bool xis_poset_id, const void *xdof, size_type xdof_size)
 Sets the dof referred to by xdof_id to the value at xdof. More...
 
virtual void get_dof (pod_index_type xdisc_id, pod_index_type xfiber_dof_id, void *xdof, size_type xdof_size) const
 Copies the dof referred to by xdisc_id, xfiber_dof_id into xdof. More...
 
virtual void put_dof (pod_index_type xdisc_id, pod_index_type xfiber_dof_id, const void *xdof, size_type xdof_size)
 Sets the dof referred to by xdof_id to the value at xdof. More...
 
virtual void get_fiber (pod_index_type xdisc_id, void *xfiber, size_type xfiber_size) const
 Sets xfiber to the fiber referred to by discretization id xdisc_id. More...
 
virtual void put_fiber (pod_index_type xdisc_id, const void *xfiber, size_type xfiber_size)
 Sets the fiber referred to by discretization id xdisc_id to xfiber. More...
 
virtual void get_component (pod_index_type xfiber_dof_id, void *xcomponent, size_type xcomponent_size) const
 Sets xcomponent to the component referred to by fiber id xfiber_dof_id. More...
 
virtual void put_component (pod_index_type xfiber_dof_id, const void *xcomponent, size_type xcomponent_size)
 Sets the component referred to by fiber id xfiber_dof_id to xcomponent. More...
 

Additional Inherited Members

- Static Protected Member Functions inherited from sheaf::poset_dof_map
static dof_map_factoryfactory ()
 The dof map factory. More...
 
- Protected Attributes inherited from sheaf::poset_dof_map
poset_state_handle_host
 The host of the poset member for which this stores the dofs. More...
 
scoped_index _index
 The poset member for which this stores the dofs. More...
 
schema_poset_member_schema
 The schema on which this is instantiated. More...
 
bool _is_table_dof_map
 True if this is a table dof map. More...
 
int _dof_ct
 The number of dofs in this map. More...
 
size_t _dof_tuple_ub
 The size of the dof tuple. More...
 
unsigned int _ref_ct
 The number of references to this map /. More...
 

Detailed Description

A contiguous tuple, contiguous fiber representation of the abstract map from section_space_schema_member ids to section dof values of homogeneous type double.

Definition at line 53 of file array_field_dof_map.h.

Constructor & Destructor Documentation

◆ array_field_dof_map() [1/3]

fiber_bundle::array_field_dof_map::array_field_dof_map ( )

Default constructor.

Error:
doesn't initialize _schema.
Postcondition

Definition at line 78 of file array_field_dof_map.cc.

References clone(), and invariant().

Referenced by allocate_dofs(), clone(), copy(), invariant(), and static_class_name().

◆ array_field_dof_map() [2/3]

fiber_bundle::array_field_dof_map::array_field_dof_map ( const array_field_dof_map xother)

Copy constructor.

Postcondition

Definition at line 134 of file array_field_dof_map.cc.

References copy(), and invariant().

◆ ~array_field_dof_map()

fiber_bundle::array_field_dof_map::~array_field_dof_map ( )
virtual

Destructor.

Definition at line 249 of file array_field_dof_map.cc.

References invariant().

Referenced by operator=().

◆ array_field_dof_map() [3/3]

fiber_bundle::array_field_dof_map::array_field_dof_map ( const sec_rep_space xhost,
void *  xdofs = 0,
size_t  xdofs_ub = 0 
)

Creates a dof map for a member of sec_rep_space xhost. If xdofs is non zero, it will be used for dof storage, otherwise storage will be allocated.

Precondition
  • xhost != 0
  • xhost->state_is_read_accessible()
  • xdofs != 0 ? xdofs_ub >= xhost->schema().row_dof_tuple_ub(): true
  • -unexecutable( "if xdofs != 0 it points to buffer of length xdofs_ub" )
Error:
isn't dof_tuple_ub the byte count?
Postcondition
  • _disc_ct > 0
  • _fiber_ct > 0
  • _local_ct > 0
  • dof_ct() == _disc_ct*_fiber_ct*_local_ct
  • _dofs != 0
  • xdofs != 0 ? _dofs == xdofs : true

Definition at line 295 of file array_field_dof_map.cc.

References fiber_bundle::sec_rep_space::df(), fiber_bundle::sec_rep_space::discretization(), sheaf::poset_dof_map::dof_ct(), sheaf::poset_dof_map::dof_tuple_ub(), get_dof(), invariant(), sheaf::subposet::member_ct(), fiber_bundle::sec_rep_space::multiplicity(), sheaf::schema_poset_member::row_dof_tuple_ub(), fiber_bundle::sec_rep_space::schema(), and sheaf::read_write_monitor_handle::state_is_read_accessible().

Member Function Documentation

◆ allocate_dofs()

void fiber_bundle::array_field_dof_map::allocate_dofs ( )
protectedvirtual

◆ class_name()

const std::string & fiber_bundle::array_field_dof_map::class_name ( ) const
virtual

The name of the actual (possibly derived) class of this instance.

Postcondition
  • !result.empty()

Reimplemented from fiber_bundle::field_dof_map.

Definition at line 34 of file array_field_dof_map.cc.

References static_class_name().

◆ clone()

fiber_bundle::array_field_dof_map * fiber_bundle::array_field_dof_map::clone ( ) const
virtual

Virtual default constructor.

Postcondition
  • result != 0
  • result->is_same_type(this)
  • postcondition_of(array_field_dof_map())

Implements sheaf::poset_dof_map.

Definition at line 108 of file array_field_dof_map.cc.

References array_field_dof_map(), and sheaf::any::is_same_type().

Referenced by array_field_dof_map().

◆ copy()

fiber_bundle::array_field_dof_map * fiber_bundle::array_field_dof_map::copy ( ) const
virtual

Virtual copy constructor.

Postcondition
  • result != 0
  • result->is_same_type(this)
  • postcondition_of(array_field_dof_map(*this))

Implements sheaf::poset_dof_map.

Definition at line 164 of file array_field_dof_map.cc.

References array_field_dof_map(), sheaf::any::is_same_type(), and operator=().

Referenced by array_field_dof_map().

◆ dof_tuple() [1/2]

void * fiber_bundle::array_field_dof_map::dof_tuple ( )
virtual

The dof tuple (mutable version).

Postcondition

Implements sheaf::poset_dof_map.

Definition at line 1074 of file array_field_dof_map.cc.

References invariant().

Referenced by put_component_dofs().

◆ dof_tuple() [2/2]

const void * fiber_bundle::array_field_dof_map::dof_tuple ( ) const
virtual

The dof tuple (const version).

Postcondition

Implements sheaf::poset_dof_map.

Definition at line 1096 of file array_field_dof_map.cc.

References get_dof_tuple(), and invariant().

◆ get_component()

void fiber_bundle::array_field_dof_map::get_component ( pod_index_type  xfiber_dof_id,
void *  xcomponent,
size_type  xcomponent_size 
) const
virtual

Sets xcomponent to the component referred to by fiber id xfiber_dof_id.

Precondition
  • schema().fiber_id_space().contains_range_id(xfiber_dof_id)
  • -unexecutable( "xcomponent points to buffer of size xcomponent_size" )
  • xcomponent_size >= schema().component_size(xfiber_dof_id)

Implements fiber_bundle::section_dof_map.

Definition at line 503 of file array_field_dof_map.cc.

References fiber_bundle::section_space_schema_member::fiber_size(), put_component(), fiber_bundle::section_dof_map::schema(), and fiber_bundle::section_space_schema_member::size().

Referenced by put_fiber().

◆ get_component_dofs() [1/2]

void fiber_bundle::array_field_dof_map::get_component_dofs ( void *  xbuf,
size_t  xbuf_len,
const scoped_index xcomp_id,
const scoped_index xdisc_ids = 0,
size_type  xdisc_ids_ct = 0 
) const
virtual

Copys the dofs associated with the fiber component identified by xcomp_id from internal storage into buffer xbuf of length xbuf_len bytes.

If xdisc_ids is not void, only the dofs associated with the discretization members identified by the xdisc_id_ct ids in xdisc_ids are transferred.

Precondition
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( "xbuf_len is large enough for the requested dofs" )
  • schema().fiber_schema().contains_row_dof(xcomp_id)
  • xdisc_ids == 0 ? xdisc_ids_ct == 0 : true
  • for(int i = ( 0 ); i < ( xdisc_ids_ct ); ++ i ) schema().discretization().contains_member(xdisc_ids[i])

Definition at line 919 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::is_initialized(), fiber_bundle::length(), put_component_dofs(), and fiber_bundle::section_dof_map::schema().

Referenced by put_component_dofs(), and put_discretization_dofs().

◆ get_component_dofs() [2/2]

void fiber_bundle::array_field_dof_map::get_component_dofs ( void *  xbuf,
size_t  xbuf_len,
const client_index &  xcomp_id,
const id_map *  xcomp_client_id_map,
const client_index *  xdisc_ids = 0,
size_type  xdisc_ids_ct = 0,
const id_map *  xdisc_client_id_map = 0 
) const
virtual

Copys the dofs associated with the fiber component identified by xcomp_id from internal storage into buffer xbuf of length xbuf_len bytes. Xcomp_client_id_map is used to convert xcomp_id from a client id to a poset member id.

If xdisc_ids is not void, only the dofs associated with the discretization members identified by the xdisc_id_ct ids in xdisc_ids are transferred. Xdisc_client_id_map is used to convert the ids in xdisc_ids from client ids to poset member ids.

Precondition
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( "xbuf_len is large enough for the requested dofs" )
  • xcomp_client_id_map != 0
  • schema().fiber_schema().contains_row_dof(scoped_index(xcomp_id, xcomp_client_id_map))
  • xdisc_ids == 0 ? xdisc_ids_ct == 0 : true
  • xdisc_ids_ct != 0 ? xdisc_client_id_map != 0 : true
  • for(int i = ( 0 ); i < ( xdisc_ids_ct ); ++ i ) schema().discretization().contains_member(scoped_index(xdisc_ids[i], xdisc_client_id_map))

Definition at line 990 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::is_initialized(), fiber_bundle::length(), put_component_dofs(), and fiber_bundle::section_dof_map::schema().

◆ get_discretization_dofs()

void fiber_bundle::array_field_dof_map::get_discretization_dofs ( const scoped_index xdisc_id,
bool  xis_poset_id,
void *  xbuf,
size_t  xbuf_len 
) const
virtual

Copys the dofs associated with the discretization member identified by xdisc_id into the buffer of length xbuf_len bytes starting at xbuf. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids.

Precondition
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • xbuf_len >= schema().fiber_schema().row_dof_tuple_ub()
  • xis_poset_id ? xdisc_id.in_scope() : true

Definition at line 833 of file array_field_dof_map.cc.

References fiber_bundle::section_space_schema_member::fiber_schema(), sheaf::scoped_index::hub_pod(), sheaf::scoped_index::in_scope(), fiber_bundle::length(), put_discretization_dofs(), sheaf::schema_poset_member::row_dof_tuple_ub(), and fiber_bundle::section_dof_map::schema().

Referenced by put_dofs().

◆ get_dof() [1/4]

void fiber_bundle::array_field_dof_map::get_dof ( pod_index_type  xdof_id,
void *  xdof,
size_type  xdof_size 
) const
virtual

Copies the dof referred to by xdof_id into xdof.

Precondition
  • schema().dof_id_space().contains_range_id(xdof_id)
  • -unexecutable( "xdof points to buffer of size xdof_size" )

Reimplemented from sheaf::poset_dof_map.

Definition at line 354 of file array_field_dof_map.cc.

References put_dof(), and fiber_bundle::section_dof_map::schema().

Referenced by array_field_dof_map(), put_component(), put_dof(), and put_dofs().

◆ get_dof() [2/4]

void fiber_bundle::array_field_dof_map::get_dof ( pod_index_type  xdisc_id,
pod_index_type  xfiber_dof_id,
void *  xdof,
size_type  xdof_size 
) const
virtual

Copies the dof referred to by xdisc_id, xfiber_dof_id into xdof.

Precondition
  • schema().discretization_id_space().contains_range_id(xdisc_id)
  • schema().fiber_id_space().contains_range_id(xfiber_dof_id)
  • -unexecutable( "xdof points to buffer of size xdof_size" )
  • xdof_size >= schema().size(xdisc_id, xfiber_dof_id)

Implements fiber_bundle::section_dof_map.

Definition at line 403 of file array_field_dof_map.cc.

References put_dof(), and fiber_bundle::section_dof_map::schema().

◆ get_dof() [3/4]

void fiber_bundle::array_field_dof_map::get_dof ( const scoped_index xid,
bool  xis_poset_id,
void *  xbuf,
size_t  xbuf_len 
) const
virtual

Copies the value of the dof referred to by the xid and xis_poset_id into the buffer of length xbuf_len bytes starting at xbuf.

Precondition
  • xis_poset_id ? schema().contains_row_dof(xid) : true
  • xbuf != 0
  • -unexecutable( "xbuf_len is large enough to contain the requested dof" )
  • -unexecutable( "xbuf is properly aligned for the type of dof" )

Definition at line 578 of file array_field_dof_map.cc.

References put_dof(), and fiber_bundle::section_dof_map::schema().

◆ get_dof() [4/4]

void fiber_bundle::array_field_dof_map::get_dof ( const scoped_index xbase_id,
const scoped_index xfiber_id,
const scoped_index xmult_id,
bool  xis_poset_id,
void *  xbuf,
size_t  xbuf_len 
) const
virtual

Copies the value of the dof referred to by the ids xbase_id, xfiber_id, and xmult_id into the buffer of length xbuf_len bytes starting at xbuf. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids.

Precondition
  • -unexecutable( xbase_id is a valid client id )
  • -unexecutable( xfiber_id is a valid client id )
  • -unexecutable( 0 <= xmult_id && xmult_id < multiplicity )
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( xbuf_len is large enough to hold the dofs referred to by client ids )
Postcondition
  • -unexecutable( xbuf holds dof referred to by xids )

Definition at line 697 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::dof(), fiber_bundle::length(), and put_dof().

◆ get_dof_tuple()

void fiber_bundle::array_field_dof_map::get_dof_tuple ( void *  xbuf,
size_t  xbuflen 
) const
virtual

Copies the entire dof tuple from internal storage into xbuf.

Precondition
  • xbuf != 0
Postcondition
  • -unexecutable( dof tuple copied to xbuf )

Implements sheaf::poset_dof_map.

Definition at line 1118 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::dof(), sheaf::poset_dof_map::dof_tuple_ub(), invariant(), and put_dof_tuple().

Referenced by dof_tuple().

◆ get_dofs() [1/2]

void fiber_bundle::array_field_dof_map::get_dofs ( const client_index *  xclient_ids,
int  xclient_id_ct,
void *  xbuf,
size_t  xbuf_len 
) const
virtual

Copies the values of the dofs referred to by the xclient_id_ct client ids in xclient_ids into the buffer of length xbuf_len bytes starting at xbuf.

Precondition
  • xclient_ids != 0
  • xclient_id_ct > 0
  • -unexecutable( xclient_ids points to buffer of length xclient_id_ct )
  • -unexecutable( xclient_ids are valid client ids )
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( xbuf_len is large enough to hold the dofs referred to by xclient_ids )
Todo:
make the precondition below executable.
Precondition
  • -unexecutable( "xbuf must be aligned for all data types" )
Not Implemented.
Postcondition
  • -unexecutable( xbuf holds dofs referred to by xclient_ids )

Reimplemented from fiber_bundle::field_dof_map.

Definition at line 634 of file array_field_dof_map.cc.

References fiber_bundle::length(), and put_dofs().

Referenced by put_dof().

◆ get_dofs() [2/2]

void fiber_bundle::array_field_dof_map::get_dofs ( const client_index *  xclient_base_ids,
int  xclient_base_id_ct,
const client_index *  xclient_fiber_ids,
int  xclient_fiber_id_ct,
void *  xbuf,
size_t  xbuf_len 
) const
virtual

Copies the values of the dofs referred to by the client ids in xclient_base_ids x xclient_fiber_ids into the buffer of length xbuf_len bytes starting at xbuf.

Precondition
  • xclient_base_ids != 0
  • xclient_base_id_ct > 0
  • -unexecutable( xclient_base_ids points to buffer of length xclient_base_id_ct )
  • -unexecutable( xclient_base_ids are valid client ids )
  • xclient_fiber_ids != 0
  • xclient_fiber_id_ct > 0
  • -unexecutable( xclient_fiber_ids points to buffer of length xclient_fiber_id_ct )
  • -unexecutable( xclient_fiber_ids are valid client ids )
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( xbuf_len is large enough to hold the dofs referred to by client ids )
Postcondition
  • -unexecutable( xbuf holds dofs referred to by xclient_ids )

Definition at line 759 of file array_field_dof_map.cc.

References invariant(), fiber_bundle::length(), and put_dofs().

◆ get_fiber()

void fiber_bundle::array_field_dof_map::get_fiber ( pod_index_type  xdisc_id,
void *  xfiber,
size_type  xfiber_size 
) const
virtual

Sets xfiber to the fiber referred to by discretization id xdisc_id.

Precondition
  • schema().discretization_id_space().contains_range_id(xdisc_id)
  • -unexecutable( "xfiber points to buffer of size xfiber_size" )

Reimplemented from fiber_bundle::section_dof_map.

Definition at line 455 of file array_field_dof_map.cc.

References put_fiber(), and fiber_bundle::section_dof_map::schema().

Referenced by put_dof().

◆ invariant()

bool fiber_bundle::array_field_dof_map::invariant ( ) const
virtual

◆ operator=()

fiber_bundle::array_field_dof_map & fiber_bundle::array_field_dof_map::operator= ( const array_field_dof_map xother)

Assignment operator.

Precondition
  • xother.is_initialized()
Error:
isn't dof_tuyple_ub the byte count?
Postcondition

Definition at line 189 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::dof_tuple_ub(), invariant(), sheaf::poset_dof_map::is_initialized(), fiber_bundle::field_dof_map::operator=(), and ~array_field_dof_map().

Referenced by copy().

◆ put_component()

void fiber_bundle::array_field_dof_map::put_component ( pod_index_type  xfiber_dof_id,
const void *  xcomponent,
size_type  xcomponent_size 
)
virtual

Sets the component referred to by fiber id xfiber_dof_id to xcomponent.

Precondition
  • schema().fiber_id_space().contains_range_id(xfiber_dof_id)
  • -unexecutable( "xcomponent points to buffer of size xcomponent_size" )
  • xcomponent_size >= schema().component_size(xfiber_dof_id)

Implements fiber_bundle::section_dof_map.

Definition at line 538 of file array_field_dof_map.cc.

References fiber_bundle::section_space_schema_member::fiber_size(), get_dof(), fiber_bundle::section_dof_map::schema(), and fiber_bundle::section_space_schema_member::size().

Referenced by get_component().

◆ put_component_dofs() [1/2]

void fiber_bundle::array_field_dof_map::put_component_dofs ( const void *  xbuf,
size_t  xbuf_len,
const scoped_index xcomp_id,
const scoped_index xdisc_ids = 0,
size_type  xdisc_ids_ct = 0 
)
virtual

Copys the dofs associated with the fiber component identified by xcomp_id from buffer xbuf of length xbuf_len bytes into internal storage.

If xdisc_ids is not void, only the dofs associated with the discretization members identified by the xdisc_id_ct ids in xdisc_ids are transferred.

Precondition
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( "xbuf_len is large enough for the requested dofs" )
  • schema().fiber_schema().contains_row_dof(xcomp_id)
  • xdisc_ids == 0 ? xdisc_ids_ct == 0 : true
  • for(int i = ( 0 ); i < ( xdisc_ids_ct ); ++ i ) schema().discretization().contains_member(xdisc_ids[i])

Definition at line 955 of file array_field_dof_map.cc.

References get_component_dofs(), sheaf::poset_dof_map::is_initialized(), fiber_bundle::length(), and fiber_bundle::section_dof_map::schema().

Referenced by get_component_dofs().

◆ put_component_dofs() [2/2]

void fiber_bundle::array_field_dof_map::put_component_dofs ( const void *  xbuf,
size_t  xbuf_len,
const client_index &  xcomp_id,
const id_map *  xcomp_client_id_map,
const client_index *  xdisc_ids = 0,
size_type  xdisc_ids_ct = 0,
const id_map *  xdisc_client_id_map = 0 
)
virtual

Copys the dofs associated with the fiber component identified by xcomp_id from buffer xbuf of length xbuf_len bytes into internal storage. Xcomp_client_id_map is used to convert xcomp_id from a client id to a poset member id.

If xdisc_ids is not void, only the dofs associated with the discretization members identified by the xdisc_id_ct ids in xdisc_ids are transferred. Xdisc_client_id_map is used to convert the ids in xdisc_ids from client ids to poset member ids.

Precondition
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( "xbuf_len is large enough for the requested dofs" )
  • xcomp_client_id_map != 0
  • schema().fiber_schema().contains_row_dof(scoped_index(xcomp_id, xcomp_client_id_map))
  • xdisc_ids == 0 ? xdisc_ids_ct == 0 : true
  • xdisc_ids_ct != 0 ? xdisc_client_id_map != 0 : true
  • for(int i = ( 0 ); i < ( xdisc_ids_ct ); ++ i ) schema().discretization().contains_member(scoped_index(xdisc_ids[i], xdisc_client_id_map))

Definition at line 1032 of file array_field_dof_map.cc.

References dof_tuple(), sheaf::poset_dof_map::is_initialized(), fiber_bundle::length(), and fiber_bundle::section_dof_map::schema().

◆ put_discretization_dofs()

void fiber_bundle::array_field_dof_map::put_discretization_dofs ( const scoped_index xdisc_id,
bool  xis_poset_id,
const void *  xbuf,
size_t  xbuf_len 
)
virtual

Copys the dofs associated with the discretization member identified by xdisc_id from the buffer of length xbuf_len bytes starting at xbuf into internal storage. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids.

Precondition
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • xbuf_len >= schema().fiber_schema().row_dof_tuple_ub()
  • xis_poset_id ? xdisc_id.in_scope() : true

Definition at line 874 of file array_field_dof_map.cc.

References fiber_bundle::section_space_schema_member::fiber_schema(), get_component_dofs(), sheaf::scoped_index::hub_pod(), sheaf::scoped_index::in_scope(), fiber_bundle::length(), sheaf::schema_poset_member::row_dof_ct(), and fiber_bundle::section_dof_map::schema().

Referenced by get_discretization_dofs().

◆ put_dof() [1/4]

void fiber_bundle::array_field_dof_map::put_dof ( pod_index_type  xdof_id,
bool  xis_poset_id,
const void *  xdof,
size_type  xdof_size 
)
virtual

Sets the dof referred to by xdof_id to the value at xdof.

Precondition
  • schema().dof_id_space().contains_range_id(xdof_id)
  • -unexecutable( "xdof points to buffer of size xdof_size" )
Postcondition
  • -unexecutable( internal storage holds dof referred to by xdof_id and xis_poset_id )

Definition at line 378 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::dof(), get_dof(), and fiber_bundle::section_dof_map::schema().

Referenced by get_dof().

◆ put_dof() [2/4]

void fiber_bundle::array_field_dof_map::put_dof ( pod_index_type  xdisc_id,
pod_index_type  xfiber_dof_id,
const void *  xdof,
size_type  xdof_size 
)
virtual

Sets the dof referred to by xdof_id to the value at xdof.

Precondition
  • schema().discretization_id_space().contains_range_id(xdisc_id)
  • schema().fiber_id_space().contains_range_id(xfiber_dof_id)
  • -unexecutable( "xdof points to buffer of size xdof_size" )
  • xdof_size >= schema().size(xdisc_id, xfiber_dof_id)

Implements fiber_bundle::section_dof_map.

Definition at line 429 of file array_field_dof_map.cc.

References get_fiber(), and fiber_bundle::section_dof_map::schema().

◆ put_dof() [3/4]

void fiber_bundle::array_field_dof_map::put_dof ( const scoped_index xid,
bool  xis_poset_id,
const void *  xbuf,
size_t  xbuf_len 
)
virtual

Copies the value of the dof referred to by the xid and xis_poset_id from the buffer of length xbuf_len bytes starting at xbuf.

Precondition
  • xis_poset_id ? schema().contains_row_dof(xid) : true
  • xbuf != 0
  • -unexecutable( "xbuf_len is large enough to contain the requested dof" )
  • -unexecutable( "xbuf is properly aligned for the type of dof" )
Todo:
make the precondition below executable.
Precondition
  • -unexecutable( "xbuf must be aligned for the given data type" )
Postcondition
  • -unexecutable( internal storage holds dof referred to by xid and xis_poset_id )

Definition at line 603 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::dof(), get_dofs(), and fiber_bundle::section_dof_map::schema().

◆ put_dof() [4/4]

void fiber_bundle::array_field_dof_map::put_dof ( const scoped_index xbase_id,
const scoped_index xfiber_id,
const scoped_index xmult_id,
bool  xis_poset_id,
const void *  xbuf,
size_t  xbuf_len 
)
virtual

Copies the value of the dof referred to by the ids in xbase_id, xfiber_id, and xmult_id from the buffer of length xbuf_len bytes starting at xbuf. If xis_poset_id is true, ids are interpretted as poset member ids, otherwise they are interpretted as client ids.

Precondition
  • -unexecutable( xbase_id is a valid client id )
  • -unexecutable( xfiber_id is a valid client id )
  • -unexecutable( 0 <= xmult_id && xmult_id < multiplicity )
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( xbuf_len is large enough to hold the dofs referred to by client ids )
Postcondition
  • -unexecutable( internal storage holds dof referred to by xids )

Definition at line 729 of file array_field_dof_map.cc.

References sheaf::poset_dof_map::dof(), get_dofs(), and fiber_bundle::length().

◆ put_dof_tuple()

void fiber_bundle::array_field_dof_map::put_dof_tuple ( const void *  xbuf,
size_t  xbuflen 
)
virtual

Copies the entire dof tuple from xbuf into internal storage.

Precondition
  • xbuf != 0
Postcondition
  • -unexecutable( xbuf copied to dof tuple )

Implements sheaf::poset_dof_map.

Definition at line 1143 of file array_field_dof_map.cc.

References allocate_dofs(), sheaf::poset_dof_map::dof(), sheaf::poset_dof_map::dof_tuple_ub(), and invariant().

Referenced by get_dof_tuple().

◆ put_dofs() [1/2]

void fiber_bundle::array_field_dof_map::put_dofs ( const client_index *  xclient_ids,
int  xclient_id_ct,
const void *  xbuf,
size_t  xbuf_len 
)
virtual

Copies the values of the dofs referred to by the xclient_id_ct client ids in xclient_ids from the buffer of length xbuf_len bytes starting at xbuf into internal storage.

Precondition
  • xclient_ids != 0
  • xclient_id_ct > 0
  • -unexecutable( xclient_ids points to buffer of length xclient_id_ct )
  • -unexecutable( xclient_ids are valid client ids )
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( xbuf_len is large enough to hold the dofs referred to by xclient_ids )
Todo:
make the precondition below executable.
Precondition
  • -unexecutable( "xbuf must be aligned for all data types" )
Not Implemented.
Postcondition
  • -unexecutable( internal storage holds dofs referred to by xclient_ids )

Reimplemented from fiber_bundle::field_dof_map.

Definition at line 665 of file array_field_dof_map.cc.

References get_dof(), and fiber_bundle::length().

Referenced by get_dofs().

◆ put_dofs() [2/2]

void fiber_bundle::array_field_dof_map::put_dofs ( const client_index *  xclient_base_ids,
int  xclient_base_id_ct,
const client_index *  xclient_fiber_ids,
int  xclient_fiber_id_ct,
const void *  xbuf,
size_t  xbuf_len 
)
virtual

Copies the values of the dofs referred to by the client ids in xclient_base_ids x xclient_fiber_ids from the buffer of length xbuf_len bytes starting at xbuf.

Precondition
  • xclient_base_ids != 0
  • xclient_base_id_ct > 0
  • -unexecutable( xclient_base_ids points to buffer of length xclient_base_id_ct )
  • -unexecutable( xclient_base_ids are valid client ids )
  • xclient_fiber_ids != 0
  • xclient_fiber_id_ct > 0
  • -unexecutable( xclient_fiber_ids points to buffer of length xclient_fiber_id_ct )
  • -unexecutable( xclient_fiber_ids are valid client ids )
  • xbuf != 0
  • -unexecutable( xbuf points to buffer of length xbuf_len )
  • -unexecutable( xbuf_len is large enough to hold the dofs referred to by xclient_ids )
Postcondition
  • -unexecutable( internal storage holds dofs referred to by xclient_ids )

Definition at line 797 of file array_field_dof_map.cc.

References get_discretization_dofs(), invariant(), and fiber_bundle::length().

◆ put_fiber()

void fiber_bundle::array_field_dof_map::put_fiber ( pod_index_type  xdisc_id,
const void *  xfiber,
size_type  xfiber_size 
)
virtual

Sets the fiber referred to by discretization id xdisc_id to xfiber.

Precondition
  • schema().discretization_id_space().contains_range_id(xdisc_id)
  • -unexecutable( "xfiber points to buffer of size xfiber_size" )

Implements fiber_bundle::section_dof_map.

Definition at line 479 of file array_field_dof_map.cc.

References get_component(), and fiber_bundle::section_dof_map::schema().

Referenced by get_fiber().

◆ static_class_name()

const std::string & fiber_bundle::array_field_dof_map::static_class_name ( )
static

The name of this class.

Postcondition
  • !result.empty()
  • result == "array_field_dof_map"

Definition at line 54 of file array_field_dof_map.cc.

References array_field_dof_map().

Referenced by class_name().

◆ type_id()

virtual dof_tuple_type fiber_bundle::array_field_dof_map::type_id ( ) const
inlinevirtual

An identifer for the type of dof tuple this is.

Implements sheaf::poset_dof_map.

Definition at line 123 of file array_field_dof_map.h.


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