Clipper
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
clipper::HKL_data_base Class Referenceabstract

HKL_data_base. More...

#include <hkl_data.h>

Inheritance diagram for clipper::HKL_data_base:
clipper::HKL_data< T > clipper::HKL_data< datatypes::ABCD< float > > clipper::HKL_data< datatypes::F_sigF< float > > clipper::HKL_data< T1 > clipper::HKL_data< T2 > clipper::CHKL_data< T >

Public Types

typedef
HKL_info::HKL_reference_index 
HKL_reference_index
 Basic HKL_reference_index: see HKL_info.
 
typedef
HKL_info::HKL_reference_coord 
HKL_reference_coord
 HKL HKL_reference_index: see HKL_info.
 

Public Member Functions

virtual void init (const HKL_info &hkl_info, const Cell &cell)
 initialiser: from parent hkl_info and cell More...
 
virtual void init (const HKL_data_base &hkl_data)
 initialiser: from another hkl_data More...
 
virtual void init (const Spacegroup &spacegroup, const Cell &cell, const HKL_sampling &hkl_sampling)
 [CLIPPER2] initialiser: from spacegroup, cell, and HKL_sampling More...
 
bool is_null () const
 test if object has been initialised More...
 
const HKL_infobase_hkl_info () const
 get the parent HKL_info object
 
const Cellbase_cell () const
 get the parent cell
 
const Spacegroupspacegroup () const
 [CLIPPER2] get spacegroup
 
const Cellcell () const
 [CLIPPER2] get cell
 
const Resolutionresolution () const
 [CLIPPER2] get resolution
 
const HKL_samplinghkl_sampling () const
 [CLIPPER2] get HKL_sampling
 
const HKL_infohkl_info () const
 [CLIPPER2] get HKL_info object
 
ftype invresolsq (const int &index) const
 get resolution by reflection index (based on true cell) More...
 
Range< ftypeinvresolsq_range () const
 get resolution limits of the list (based on true cell and missing data) More...
 
int num_obs () const
 get number of observations in this list (based on missing data) More...
 
virtual void update ()=0
 update: synchornize info with parent HKL_info
 
virtual String type () const =0
 get data type (a list of names corresponding to the im/export values)
 
virtual bool missing (const int &index) const =0
 check if a data entry in the list is marked as 'missing'
 
virtual void set_null (const int &index)=0
 set data entry in the list to its null value
 
virtual int data_size () const =0
 return number of data elements in this type
 
virtual String data_names () const =0
 return names of data elements in this type
 
virtual void data_export (const HKL &hkl, xtype array[]) const =0
 conversion to array (for I/O)
 
virtual void data_import (const HKL &hkl, const xtype array[])=0
 conversion from array (for I/O)
 
virtual void mask (const HKL_data_base &mask)=0
 mask the data by marking any data missing in 'mask' as missing
 
HKL_reference_index first () const
 return HKL_reference_index pointing to first reflection More...
 
HKL_reference_index first_data () const
 return HKL_reference_index pointing to first non-missing data More...
 
HKL_reference_indexnext_data (HKL_reference_index &ih) const
 increment HKL_reference_index to next non-missing data More...
 
void debug () const
 

Protected Member Functions

 HKL_data_base ()
 null constructor More...
 
virtual ~HKL_data_base ()
 destructor
 

Protected Attributes

const HKL_infoparent_hkl_info
 
const Cellparent_cell
 
bool cell_matches_parent
 
ObjectCache< HKL_data_cacheobj >
::Reference 
cacheref
 object cache ref
 
Spacegroup spacegroup_
 
Cell cell_
 
HKL_sampling hkl_sampling_
 
Resolution resolution_
 

Detailed Description

HKL_data_base.

This is the virtual base for the typed hkl_data objects. It exists to guarantee and interface by which data can be managed without knowledge of the specific data type.

Constructor & Destructor Documentation

clipper::HKL_data_base::HKL_data_base ( )
protected

null constructor

For later initialisation: see init()

Member Function Documentation

void clipper::HKL_data_base::init ( const HKL_info hkl_info,
const Cell cell 
)
virtual

initialiser: from parent hkl_info and cell

Initialise the object using a given reflection list and cell.

Parameters
hkl_infoThe reflection list object.
cellThe unit cell for this datalist.

Reimplemented in clipper::HKL_data< T >, clipper::HKL_data< T1 >, clipper::HKL_data< T2 >, clipper::HKL_data< datatypes::F_sigF< float > >, clipper::HKL_data< datatypes::ABCD< float > >, and clipper::CHKL_data< T >.

void clipper::HKL_data_base::init ( const HKL_data_base hkl_data)
virtual

initialiser: from another hkl_data

Initialise the object using a given reflection list and cell.

Parameters
hkl_dataObject from which to inherit spacegrpoup, cell, sampling.

Reimplemented in clipper::HKL_data< T >, clipper::HKL_data< T1 >, clipper::HKL_data< T2 >, clipper::HKL_data< datatypes::F_sigF< float > >, and clipper::HKL_data< datatypes::ABCD< float > >.

void clipper::HKL_data_base::init ( const Spacegroup spacegroup,
const Cell cell,
const HKL_sampling hkl_sampling 
)
virtual

[CLIPPER2] initialiser: from spacegroup, cell, and HKL_sampling

Initialise the object using a given spacegroup, cell, and sampling.

Parameters
spacegroupThe spacegroup for this datalist.
cellThe unit cell for this datalist.
hkl_samplingThe reflection list description.

Reimplemented in clipper::HKL_data< T >, clipper::HKL_data< T1 >, clipper::HKL_data< T2 >, clipper::HKL_data< datatypes::F_sigF< float > >, clipper::HKL_data< datatypes::ABCD< float > >, and clipper::CHKL_data< T >.

bool clipper::HKL_data_base::is_null ( ) const

test if object has been initialised

Returns
true if the object has not been initalised.
ftype clipper::HKL_data_base::invresolsq ( const int &  index) const

get resolution by reflection index (based on true cell)

Return the resolution of a particular reflection. If the cell of this list closely matches (to within 0.5A) the cell of the parent list, this is a simple lookup, otherwise a metric calculation is required.

Range< ftype > clipper::HKL_data_base::invresolsq_range ( ) const

get resolution limits of the list (based on true cell and missing data)

Returns
The high and low resolution limits of the non-missing data.
int clipper::HKL_data_base::num_obs ( ) const

get number of observations in this list (based on missing data)

Returns
The number of non-missing data in the object.
HKL_info::HKL_reference_index clipper::HKL_data_base::first ( ) const

return HKL_reference_index pointing to first reflection

Returns
HKL reference to the first data in this object.
HKL_info::HKL_reference_index clipper::HKL_data_base::first_data ( ) const

return HKL_reference_index pointing to first non-missing data

Returns
HKL reference to the first non-missing data in this object.
HKL_info::HKL_reference_index & clipper::HKL_data_base::next_data ( HKL_info::HKL_reference_index ih) const

increment HKL_reference_index to next non-missing data

Parameters
ihThe HKL reference to increment.
Returns
HKL reference to the next non-missing data in this object.

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