/[escript]/branches/arrayview_from_1695_trunk/escript/src/DataTagged.h
ViewVC logotype

Diff of /branches/arrayview_from_1695_trunk/escript/src/DataTagged.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1697 by jfenwick, Mon Aug 11 06:29:54 2008 UTC revision 1704 by jfenwick, Thu Aug 14 05:35:32 2008 UTC
# Line 228  class DataTagged : public DataAbstract { Line 228  class DataTagged : public DataAbstract {
228    getPointOffset(int sampleNo,    getPointOffset(int sampleNo,
229                   int dataPointNo) const;                   int dataPointNo) const;
230    
231    
232    
233    /**    /**
234       \brief       \brief
235       addTaggedValues       addTaggedValues
# Line 267  class DataTagged : public DataAbstract { Line 269  class DataTagged : public DataAbstract {
269    
270    /**    /**
271       \brief       \brief
272         addTag - does not modify the default value for this object.
273    
274         Description:
275         Add a single tag. The default value for this DataTagged will be associated with the tag.
276         If this tag already has a value associated with it, setTaggedValue will be used to update this value.
277         \param tagKey - Input - Integer tag.
278        T
279      */
280      ESCRIPT_DLL_API
281      void
282      addTag(int tagKey);
283    
284    
285      /**
286         \brief
287       setTaggedValues       setTaggedValues
288    
289       Description:       Description:
# Line 317  class DataTagged : public DataAbstract { Line 334  class DataTagged : public DataAbstract {
334    
335    /**    /**
336       \brief       \brief
337         getDataByTag
338    
339         Return a pointer to the beginning of the datapoint with the specified tag.
340         TODO Eventually these should be inlined.
341         \param tag - Input - Integer key.
342         \param i - position in the underlying datastructure
343        T
344      */
345      ESCRIPT_DLL_API
346      DataTypes::ValueType::const_reference
347      getDataByTag(int tag, DataTypes::ValueType::size_type i) const;
348    
349      ESCRIPT_DLL_API
350      DataTypes::ValueType::reference
351      getDataByTag(int tag, DataTypes::ValueType::size_type i);
352    
353    
354      /**
355         \brief
356       getDataPoint       getDataPoint
357    
358       Description:       Description:
# Line 390  class DataTagged : public DataAbstract { Line 426  class DataTagged : public DataAbstract {
426    
427    /**    /**
428       \brief       \brief
429         getDefaultValue
430    
431         Description:
432         Return the default value. This value is associated with any tag which
433         is not explicitly recorded in this DataTagged object's tag map.
434         \param i - position in the underlying datastructure
435        T
436      */
437      ESCRIPT_DLL_API
438      DataTypes::ValueType::reference
439      getDefaultValue(DataTypes::ValueType::size_type i);
440    
441      ESCRIPT_DLL_API
442      DataTypes::ValueType::const_reference
443      getDefaultValue(DataTypes::ValueType::size_type i) const;
444    
445    
446    
447    
448      /**
449         \brief
450       getLength       getLength
451    
452       Description:       Description:
# Line 597  DataTagged::getDefaultValue() const Line 654  DataTagged::getDefaultValue() const
654  }  }
655    
656  inline  inline
657    DataTypes::ValueType::reference
658    DataTagged::getDefaultValue(DataTypes::ValueType::size_type i)
659    {
660        return getPointDataView().getData()[i];
661    }
662    
663    inline
664    DataTypes::ValueType::const_reference
665    DataTagged::getDefaultValue(DataTypes::ValueType::size_type i) const
666    {
667        return getPointDataView().getData()[i];
668    }
669    
670    
671    
672    
673    inline
674  const DataTypes::ValueType::ElementType*  const DataTypes::ValueType::ElementType*
675  DataTagged::getData() const  DataTagged::getData() const
676  {  {

Legend:
Removed from v.1697  
changed lines
  Added in v.1704

  ViewVC Help
Powered by ViewVC 1.1.26