SC_AUTO_VEC(3)

πŸ“¦
version 2.3.1 Β· 5 versions
, in ubuntu jammy

okay bestie, welcome to the sc::auto_vec< T >(3) page from the MPQC manual β€” it's giving "array-owning auto_ptr" energy, and we're gonna read every single line together. πŸ’…

πŸ’– NAME πŸ’–

sc::auto_vec< T > β€” the auto_vec class functions much like auto_ptr, except it contains references to arrays. periodt. ✨

✨ SYNOPSIS ✨

#include <autovec.h>

πŸŽ€ Public Types πŸŽ€

  • typedef T element_type β€” the element type is literally T, bestie. 🫢

🌸 Public Member Functions 🌸

  • auto_vec (T *d=0) throw () β€” creates a new auto_vec for a vector, d, of type T. πŸŽ€
  • auto_vec (auto_vec &av) throw () β€” creates an auto_vec, transferring the storage from another. πŸ¦‹
  • ~auto_vec () throw () β€” this will delete the vector. bye bestie πŸ‘‹
  • auto_vec & operator= (auto_vec &av) throw () β€” this member transfers the data from av to this. πŸ’–
  • T * get () const throw () β€” returns the pointer. ✨
  • T & operator[] (size_t i) throw () β€” returns the i'th element. 🌸
  • T * release () throw () β€” release ownership. no cap, it's right there. πŸ”“
  • void reset (T *d=0) throw () β€” assign to a new value. πŸ’…

πŸ¦‹ Detailed Description πŸ¦‹

template<class T>
class sc::auto_vec< T >"

The auto_vec class functions much like auto_ptr, except it contains references to arrays. The delete[] operator will be used to deallocate data. Slay. πŸ”₯

πŸ’… Constructor & Destructor Documentation πŸ’…

  • template<class T > sc::auto_vec< T >::auto_vec (T * d = 0) [inline], [explicit] β€” creates a new auto_vec for a vector, d, of type T. The d argument must be created with the vector new operator: new T[...]. πŸ‘‘

πŸ‘‘ Author πŸ‘‘

Generated automatically by Doxygen for MPQC from the source code. β€” iconic, honestly. 😭


signed, sealed, delivered: Version 2.3.1 on Sun Oct 4 2020 β€” sc::auto_vec< T >(3) πŸ’…βœ¨

πŸ“¦ where this page comes from