/** * setIsBuffered is a really nasty operation, made possible only because * BufPool is derived from Pool and has no other fields. * It uses a low-level replaceCinfo call to just change the * identity of the Cinfo used, leaving everything else as is. */ void Pool::vSetIsBuffered( const Eref& e, bool v ) { static const Cinfo* bufPoolCinfo = Cinfo::find( "BufPool" ); if (vGetIsBuffered( e ) == v) return; if (v) { e.element()->replaceCinfo( bufPoolCinfo ); } else { e.element()->replaceCinfo( poolCinfo ); } }
bool PoolBase::getIsBuffered( const Eref& e ) const { return vGetIsBuffered( e ); }