Public Member Functions

JDXarray< A, J > Class Template Reference
[JCAMP-DX implementation (odinpara library)]

#include <jdxarrays.h>

Inheritance diagram for JDXarray< A, J >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 JDXarray ()
 JDXarray (const A &a, const STD_string &name="", bool userParameter=true, compatMode mode=notBroken, parameterMode parameter_mode=edit, const STD_string &parx_equivalent="", float parx_assign_factor=1.0, float parx_assign_offset=0.0)
 JDXarray (const JDXarray< A, J > &ja)
JDXarray< A, J > & operator= (const A &a)
JDXarray< A, J > & operator= (const J &jv)
JDXarray< A, J > & operator= (const JDXarray< A, J > &ja)
STD_ostream & print2stream (STD_ostream &os) const
STD_string printvalstring () const
bool parsevalstring (const STD_string &parstring)
STD_string get_parx_code (parxCodeType type, const ParxEquiv &equiv) const
ParxEquiv get_parx_equiv () const
GuiProps get_gui_props () const
JcampDxClassset_gui_props (const GuiProps &gp)
const char * get_typeInfo () const
JcampDxClasscreate_copy () const
int write (const STD_string &filename) const
int load (const STD_string &filename)

Detailed Description

template<class A, class J>
class JDXarray< A, J >

JCAMP-DX template class for representing multi-dimensional arrays

Definition at line 42 of file jdxarrays.h.


Constructor & Destructor Documentation

template<class A, class J>
JDXarray< A, J >::JDXarray (  )  [inline]

Default constructor

Definition at line 49 of file jdxarrays.h.

template<class A, class J>
JDXarray< A, J >::JDXarray ( const A &  a,
const STD_string &  name = "",
bool  userParameter = true,
compatMode  mode = notBroken,
parameterMode  parameter_mode = edit,
const STD_string &  parx_equivalent = "",
float  parx_assign_factor = 1.0,
float  parx_assign_offset = 0.0 
)

Constructor with the following arguments:

  • a: Initial value for the array base class
  • name: The label of the JCAMP-DX parameter
  • userParameter: Whether this is a user defined JCAMP-DX parameter
  • mode: Mode for ASCII representation of strings or arrays of strings
  • parameter_mode: Mode for GUI accesibility of the parameter
  • parx_equivalent: Equivalent parameter in PARX to which this parameter will be assigned
  • parx_assign_factor: Scaling factor when assigning to the equivalent parameter in PARX
  • parx_assign_offset: Offset when assigning to the equivalent parameter in PARX
template<class A, class J>
JDXarray< A, J >::JDXarray ( const JDXarray< A, J > &  ja  )  [inline]

Assignment from scalar, i.e. fill all elements with this value Copy constructor

Definition at line 75 of file jdxarrays.h.


Member Function Documentation

template<class A, class J>
JcampDxClass* JDXarray< A, J >::create_copy (  )  const [inline, virtual]

Returns a deep copy of the parameter

Implements JcampDxClass.

Reimplemented in JDXtriple.

Definition at line 102 of file jdxarrays.h.

template<class A, class J>
GuiProps JDXarray< A, J >::get_gui_props (  )  const [inline, virtual]

Returns the properties of axis display in the GUI, only useful for JDXarrays

Reimplemented from JcampDxClass.

Definition at line 99 of file jdxarrays.h.

template<class A, class J>
STD_string JDXarray< A, J >::get_parx_code ( parxCodeType  type,
const ParxEquiv equiv 
) const [virtual]

Returns C code that can be used together with the PARX(Bruker) compiler.

Reimplemented from JcampDxClass.

template<class A, class J>
ParxEquiv JDXarray< A, J >::get_parx_equiv (  )  const [inline, virtual]

Returns the name and scaling of an equivalent parameter in PARX. Code for automatic mapping to the PARX parameter space can be generated using the function get_parx_code().

Reimplemented from JcampDxClass.

Definition at line 98 of file jdxarrays.h.

template<class A, class J>
const char* JDXarray< A, J >::get_typeInfo (  )  const [virtual]

Returns a string describing the type of the parameter

Implements JcampDxClass.

Reimplemented in JDXtriple.

template<class A, class J>
int JDXarray< A, J >::load ( const STD_string &  filename  )  [inline, virtual]

Loads the parameter(s) from a JCAMP-DX file. In case of calling this function of a single paramter, the file is searched for this parameter and the value is assigned. In case of a parameter block, all parameter values are taken from the file. The return value is the number of parameters which are successfully parsed. If an error occurs, -1 is returned.

Reimplemented from JcampDxClass.

Definition at line 109 of file jdxarrays.h.

template<class A, class J>
JDXarray<A,J>& JDXarray< A, J >::operator= ( const A &  a  ) 

Assignment operator from an array

template<class A, class J>
JDXarray<A,J>& JDXarray< A, J >::operator= ( const J &  jv  )  [inline]

Assignment operator from scalar, i.e. fill all elements with this value

Definition at line 85 of file jdxarrays.h.

template<class A, class J>
JDXarray<A,J>& JDXarray< A, J >::operator= ( const JDXarray< A, J > &  ja  ) 

Copy assignment

template<class A, class J>
bool JDXarray< A, J >::parsevalstring ( const STD_string &   )  [virtual]

Parses and assigns the value in the given string

Implements JcampDxClass.

template<class A, class J>
STD_ostream& JDXarray< A, J >::print2stream ( STD_ostream &  os  )  const [virtual]

Passes the parameter in ASCII format to the ostream 'os'

Reimplemented from JcampDxClass.

template<class A, class J>
STD_string JDXarray< A, J >::printvalstring (  )  const [virtual]

Returns the value of the parameter as a string

Implements JcampDxClass.

template<class A, class J>
JcampDxClass& JDXarray< A, J >::set_gui_props ( const GuiProps  )  [inline, virtual]

Sets the properties of axis display in the GUI, only useful for JDXarrays

Reimplemented from JcampDxClass.

Definition at line 100 of file jdxarrays.h.

template<class A, class J>
int JDXarray< A, J >::write ( const STD_string &  filename  )  const [inline, virtual]

Writes the parameter(s) to a JCAMP-DX file. In case of calling this function of a single paramter, the file will consist of only this parameter. In case of a parameter block, all parameter values are written to the file. If an error occurs, -1 is returned.

Reimplemented from JcampDxClass.

Definition at line 108 of file jdxarrays.h.


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