Lines Matching refs:ValueInternalLink
19 * sizeof(ValueInternalLink) );
22 ValueInternalLink::ValueInternalLink() : previous_(0), next_(0) {} function in Json::ValueInternalLink
24 ValueInternalLink::~ValueInternalLink() {
47 virtual ValueInternalLink* allocateMapBuckets(unsigned int size) {
48 return new ValueInternalLink[size];
51 virtual void releaseMapBuckets(ValueInternalLink* links) { delete[] links; }
53 virtual ValueInternalLink* allocateMapLink() {
54 return new ValueInternalLink();
57 virtual void releaseMapLink(ValueInternalLink* link) { delete link; }
82 virtual ValueInternalLink* allocateMapBuckets(unsigned int size) {
83 return new ValueInternalLink[size];
86 virtual void releaseMapBuckets(ValueInternalLink* links) { delete[] links; }
88 virtual ValueInternalLink* allocateMapLink() {
89 ValueInternalLink* link = linksAllocator_.allocate();
90 memset(link, 0, sizeof(ValueInternalLink));
94 virtual void releaseMapLink(ValueInternalLink* link) {
95 link->~ValueInternalLink();
101 BatchAllocator<ValueInternalLink, 1> linksAllocator_;
154 ValueInternalLink* link = buckets_[bucketIndex].next_;
156 ValueInternalLink* linkToRelease = link;
166 ValueInternalLink* tempBuckets = buckets_;
169 ValueInternalLink* tempTailLink = tailLink_;
200 // ValueInternalLink::itemPerLink) / ValueInternalLink::itemPerLink;
209 for (const ValueInternalLink* current = &buckets_[bucketIndex]; current != 0;
211 for (BucketIndex index = 0; index < ValueInternalLink::itemPerLink;
231 ValueInternalLink** previous = 0;
233 for (ValueInternalLink* current = &buckets_[bucketIndex]; current != 0;
235 for (index = 0; index < ValueInternalLink::itemPerLink; ++index) {
253 for (ValueInternalLink* link = &buckets_[bucketIndex]; link != 0;
256 for (index = 0; index < ValueInternalLink::itemPerLink; ++index) {
267 void ValueInternalMap::doActualRemove(ValueInternalLink* link,
274 ValueInternalLink*& lastLink = getLastLinkInBucket(index);
276 for (; lastItemIndex < ValueInternalLink::itemPerLink;
290 ValueInternalLink* linkPreviousToLast = lastLink->previous_;
305 ValueInternalLink*&
309 ValueInternalLink*& previous = buckets_[bucketIndex + 1].previous_;
317 ValueInternalLink* link,
332 ValueInternalLink*& previousLink = getLastLinkInBucket(bucketIndex);
333 ValueInternalLink* link = previousLink;
335 for (index = 0; index < ValueInternalLink::itemPerLink; ++index) {
339 if (index == ValueInternalLink::itemPerLink) // need to add a new page
341 ValueInternalLink* newLink = mapAllocator()->allocateMapLink();
419 if (iterator.itemIndex_ == ValueInternalLink::itemPerLink) {
441 iterator.itemIndex_ = ValueInternalLink::itemPerLink - 1;