1
/* Copyright (C) 2003 MySQL AB
3
This program is free software; you can redistribute it and/or modify
4
it under the terms of the GNU General Public License as published by
5
the Free Software Foundation; version 2 of the License.
7
This program is distributed in the hope that it will be useful,
8
but WITHOUT ANY WARRANTY; without even the implied warranty of
9
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10
GNU General Public License for more details.
12
You should have received a copy of the GNU General Public License
13
along with this program; if not, write to the Free Software
14
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
26
friend class DynArr256;
30
void init(Uint32 type_id, const Pool_context& pc);
36
struct DA256Page* m_memroot;
48
Head() { m_ptr_i = RNIL; m_sz = 0;}
53
bool isEmpty() const { return m_sz == 0;}
56
DynArr256(DynArr256Pool & pool, Head& head) :
57
m_head(head), m_pool(pool){}
59
Uint32* set(Uint32 pos);
60
Uint32* get(Uint32 pos) const ;
62
struct ReleaseIterator
69
void init(ReleaseIterator&);
72
* 1 - data (in retptr)
75
Uint32 release(ReleaseIterator&, Uint32* retptr);
78
DynArr256Pool & m_pool;
80
bool expand(Uint32 pos);
81
void handle_invalid_ptr(Uint32 pos, Uint32 ptrI, Uint32 p0);