| 1 | |
|---|
| 2 | /****************************************************************************** |
|---|
| 3 | * $Id$ |
|---|
| 4 | * |
|---|
| 5 | * Project: libsidx - A C API wrapper around libspatialindex |
|---|
| 6 | * Purpose: C++ objects to implement the count visitor. |
|---|
| 7 | * Author: Leonard Norrgård, leonard.norrgard@refactor.fi |
|---|
| 8 | * |
|---|
| 9 | ****************************************************************************** |
|---|
| 10 | * Copyright (c) 2010, Leonard Norrgård |
|---|
| 11 | * |
|---|
| 12 | * All rights reserved. |
|---|
| 13 | * |
|---|
| 14 | * This library is free software; you can redistribute it and/or modify it under |
|---|
| 15 | * the terms of the GNU Lesser General Public License as published by the Free |
|---|
| 16 | * Software Foundation; either version 2.1 of the License, or (at your option) |
|---|
| 17 | * any later version. |
|---|
| 18 | |
|---|
| 19 | * This library is distributed in the hope that it will be useful, but WITHOUT |
|---|
| 20 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
|---|
| 21 | * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more |
|---|
| 22 | * details. |
|---|
| 23 | * |
|---|
| 24 | * You should have received a copy of the GNU Lesser General Public License |
|---|
| 25 | * along with this library; if not, write to the Free Software Foundation, Inc., |
|---|
| 26 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
|---|
| 27 | ****************************************************************************/ |
|---|
| 28 | |
|---|
| 29 | #include "sidx_impl.h" |
|---|
| 30 | |
|---|
| 31 | CountVisitor::CountVisitor(): nResults(0) |
|---|
| 32 | { |
|---|
| 33 | } |
|---|
| 34 | |
|---|
| 35 | CountVisitor::~CountVisitor() |
|---|
| 36 | { |
|---|
| 37 | |
|---|
| 38 | } |
|---|
| 39 | |
|---|
| 40 | void CountVisitor::visitNode(const SpatialIndex::INode& n) |
|---|
| 41 | { |
|---|
| 42 | |
|---|
| 43 | } |
|---|
| 44 | |
|---|
| 45 | void CountVisitor::visitData(const SpatialIndex::IData& d) |
|---|
| 46 | { |
|---|
| 47 | nResults += 1; |
|---|
| 48 | } |
|---|
| 49 | |
|---|
| 50 | void CountVisitor::visitData(std::vector<const SpatialIndex::IData*>& v) |
|---|
| 51 | { |
|---|
| 52 | } |
|---|