DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dunedaq::oks::OksString Class Reference

Class OKS string. More...

#include <object.hpp>

Inheritance diagram for dunedaq::oks::OksString:
[legend]
Collaboration diagram for dunedaq::oks::OksString:
[legend]

Public Member Functions

 OksString ()
 to deallocate memory when destroyed
 OksString (const std::string &s)
 OksString (const char *s)
 OksString (const char *s, size_t n)
 OksString (const std::string &s, std::string::size_type n)
void * operator new (size_t)
void operator delete (void *ptr)

Friends

class OksKernel

Detailed Description

Class OKS string.

The class OksString is inherited from C++ Standard Library string class but uses private memory allocator for instances (is used for performance optimisation)

Definition at line 416 of file object.hpp.

Constructor & Destructor Documentation

◆ OksString() [1/5]

dunedaq::oks::OksString::OksString ( )
inline

to deallocate memory when destroyed

Definition at line 421 of file object.hpp.

421{ ; }

◆ OksString() [2/5]

dunedaq::oks::OksString::OksString ( const std::string & s)
inline

Definition at line 422 of file object.hpp.

423 : std::string(s)
424 {
425 ;
426 }

◆ OksString() [3/5]

dunedaq::oks::OksString::OksString ( const char * s)
inline

Definition at line 427 of file object.hpp.

428 : std::string(s)
429 {
430 ;
431 }

◆ OksString() [4/5]

dunedaq::oks::OksString::OksString ( const char * s,
size_t n )
inline

Definition at line 432 of file object.hpp.

433 : std::string(s, n)
434 {
435 ;
436 }

◆ OksString() [5/5]

dunedaq::oks::OksString::OksString ( const std::string & s,
std::string::size_type n )
inline

Definition at line 437 of file object.hpp.

438 : std::string(s, 0, n)
439 {
440 ;
441 }

Member Function Documentation

◆ operator delete()

void dunedaq::oks::OksString::operator delete ( void * ptr)
inline

Definition at line 444 of file object.hpp.

445 {
446 boost::fast_pool_allocator<OksString>::deallocate(reinterpret_cast<OksString*>(ptr));
447 }
OksString()
to deallocate memory when destroyed
Definition object.hpp:421

◆ operator new()

void * dunedaq::oks::OksString::operator new ( size_t )
inline

Definition at line 443 of file object.hpp.

443{ return boost::fast_pool_allocator<OksString>::allocate(); }

◆ OksKernel

friend class OksKernel
friend

Definition at line 418 of file object.hpp.


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