#ifndef BooSArr1_HH #define BooSArr1_HH ////////////////////////////////////////////////////////////////////////// //! file="amma/Contain/Array/SArray/BooSArr1.hh" //! lib=MSArr1 //! userlevel=Normal //! author="Radek Marik" //! docentry="Containers.Arrays.1-D Arrays" //! rcsid="$Id: BooSArr1.hh,v 1.12 1999/03/29 11:15:09 ees1cg Exp $" //! date="20/2/1995" #include "amma/Boolean.hh" #include "amma/SArray1d.hh" //======================================================================== //================= BoolSArray1dC ======================================== //======================================================================== //: A simple 1 dimensional array of logical variables // The class BoolSArray1dC is a simple container with a fixed number // of logical values which can accessed randomly using indexing. // The class BoolSArray1dC is a big object, eg. it has a reference counter. // BIG OBJECT class BoolSArray1dC: public SArray1dC { public: // Constructors, copies, assigment, and destructor. // ---------------------------------------- BoolSArray1dC(); // Creates the empty array. BoolSArray1dC(const SizeT dim); // Creates the non-initialized array with the range <0, 'dim'-1>. BoolSArray1dC(const SizeT dim, BooleanT v); // Creates the array with the range <0, 'dim'-1> initialized to the // value 'v'. BoolSArray1dC(const BoolSArray1dC & vv); // Another access to the array 'vv'. BoolSArray1dC(const SArray1dC & vv); // Another access to the array 'vv'. BoolSArray1dC(BooleanT * data, const SizeT dim); // An array is created from the memory location 'data' with the range // of access in <0, 'dim'-1>. // 'data' is not deallocated during destructing of the array. BoolSArray1dC(istream & s); // Creates the array from the input stream 's'. BoolSArray1dC Copy() const; // Creates a new physical copy of the array. inline const BoolSArray1dC & operator=(const BoolSArray1dC & vv); // Assigment, as for a BIG_OBJECT. // Operators. // ---------- const BoolSArray1dC & operator|=(const BoolSArray1dC & ba); // Logical OR item by item. }; ostream & operator<<(ostream & s, const BoolSArray1dC & arr); // Prints array into the stream 's'. istream & operator>>(istream & s, BoolSArray1dC & arr); // Assigns the values into the array 'arr'. ///////////////////////////////////////////////////// inline const BoolSArray1dC & BoolSArray1dC::operator=(const BoolSArray1dC & vv) //================================================ { SArray1dC::operator=(vv); return *this; } #endif // IAPS - Image analysis program system. // End of include file BooSArr1.hh