User Documentation
Centre for Vision, Speech & Signal Processing
DEVELOP IN NAMESPACE AMMA TREE ROOT AMMA SEARCH AMMA HOME
 

  PUBLIC
SizeBufferAccessC::SizeBufferAccessC(DataC *,SizeT)
SizeBufferAccessC::SizeBufferAccessC(const BufferAccessC &,const BufferSizeC &)
SizeBufferAccessC::SizeBufferAccessC(const SizeBufferAccessC &)
SizeBufferAccessC::SizeBufferAccessC(const SizeBufferAccessC &,const BufferSizeC &)
SizeBufferAccessC::operator=(DataC *)
SizeBufferAccessC::ReferenceElm(void) const
SizeBufferAccessC::ReferenceVoid(void) const
SizeBufferAccessC::Access(void) const
SizeBufferAccessC::DataStart(void) const
SizeBufferAccessC::N(void) const
SizeBufferAccessC::Size(void) const
SizeBufferAccessC::Limits(void) const
SizeBufferAccessC::Range(void) const
SizeBufferAccessC::IMin(void) const
SizeBufferAccessC::IMax(void) const
SizeBufferAccessC::operator[](const IndexT) const
SizeBufferAccessC::operator[](const IndexT)
SizeBufferAccessC::SAccess(void) const
SizeBufferAccessC::IsEmpty(void) const
SizeBufferAccessC::Contains(const IndexT) const
SizeBufferAccessC::ShrinkHigh(const SizeT)
SizeBufferAccessC::Swap(SizeBufferAccessC &)
SizeBufferAccessC::Attach(const SizeBufferAccessC &)
SizeBufferAccessC::Attach(const BufferAccessC &,const SizeT)
SizeBufferAccessC::operator+(const SizeT) const
SizeBufferAccessC::Fill(const DataC &)
SizeBufferAccessC::CopyFrom(const SizeBufferAccessC &)
SizeBufferAccessC<class DataC>
 
Basic access to buffer with limited size
 
include "amma/SBfAcc.hh"
User Level:Default
Library:Mbuff
Example:exBRefC.cc
Section:Containers.Arrays.Buffer
In Scope:std

Comments:
The class SizeBufferAccessC enables to random indexed access to a sequentially organised continous part of memory called buffer. The access functions check if an accessed element is valid only in debug mode.

Parent Classes: Derived Classes: Typedefs:
typedef DataC ElementT;
Constructors, copies, assigment, and destructor -----------------------------------------------

Variables:
Methods:
SizeBufferAccessC(DataC * bp = 0,SizeT size = 0)
Creates an access to a buffer pointed by the pointer 'bp'. If 'bp' is 0, the access is not valid.

SizeBufferAccessC(const BufferAccessC<DataC> & bp,const BufferSizeC & s)
Creates an access to a buffer referenced by 'bp' with size 's'.

SizeBufferAccessC(const SizeBufferAccessC<DataC> & ba)
Creates a physical copy of the access 'ba'.

SizeBufferAccessC(const SizeBufferAccessC<DataC> & ba,const BufferSizeC & s)
Creates a physical copy of the access 'ba' limited by new size 's'.

const SizeBufferAccessC<DataC> & operator=(DataC * bp)
Changes the reference element to the element pointed by 'bp'. Access to the object --------------------

DataC * ReferenceElm(void) const
Returns the pointer to the reference element of the attached buffer. The reference element need not to be the valid element of the buffer.

void * ReferenceVoid(void) const
Returns the pointer to the reference element of the attached buffer. The reference element need not to be the valid element of the buffer. The function is intended to be used in printing.

const BufferAccessC<DataC> & Access(void) const
Returns this object.

DataC * DataStart() const
Returns the address of the first element of the buffer.

SizeT N() const
Returns the number of elements of the array.

SizeT Size() const
Returns the number of elements of the array.

const BufferSizeC & Limits() const
Returns the usable range of indeces expressed by this object.

const BufferSizeC & Range() const
Returns the usable range of indeces expressed by this object.

IndexT IMin() const
Returns the minimum index of the range of this access.

IndexT IMax() const
Returns the maximum index of the range of this access.

const DataC & operator[](const IndexT i) const
Read-only access to the ('i'+1)-th element of the buffer.

DataC & operator[](const IndexT i)
Read-write access to the ('i'+1)-th element of the buffer.

const SizeBufferAccessC<DataC> & SAccess(void) const
Returns this object. Logical functions -----------------

BooleanT IsEmpty() const
Returns TRUE if the size of the array is zero.

BooleanT Contains(const IndexT i) const
Returns TRUE if the array contains an item with the index 'i'. Modifications of the access ---------------------------

const BufferSizeC & ShrinkHigh(const SizeT k)
Changes the number of elements by subtracting the last 'k' elements.

const SizeBufferAccessC<DataC> & Swap(SizeBufferAccessC<DataC> & a)
Exchanges the contents of this buffer with buffer 'a'.

void Attach(const SizeBufferAccessC<DataC> & b)
Changes this buffer access to have the same access rights as 'b'.

void Attach(const BufferAccessC<DataC> & b,const SizeT size)
Changes this buffer access to have the access rights as 'b' limited for 'size' elements.

SizeBufferAccessC<DataC> operator+(const SizeT i) const
Creates the new access object shifted 'i' elements to the right (towards next elements). The size is descreased to fit the the original range of this access. Modifications of the buffer contents ------------------------------------

void Fill(const DataC & d)
'd' value is assigned to all elements of the buffer.

void CopyFrom(const SizeBufferAccessC<DataC> & oth)
Copy contents of another buffer into this one.
NB. Buffers MUST be the same length.


Programmer:Radek Marik, Documentation by CxxDoc: Tue Mar 20 10:48:08 2001