⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gist_rtpred.cc

📁 Libgist is an implementation of the Generalized Search Tree, a template index structure that makes i
💻 CC
字号:
// gist_rtpred_base.cc						-*- c++ -*-// Copyright (c) 1998, Regents of the University of California// $Id: gist_rtpred.cc,v 1.2 1998/09/24 05:22:05 marcel Exp $#ifdef __GNUG__#pragma implementation "gist_rtpred.h"#endif#include "gist_defs.h"		// for assert()#include "gist_rtpred.h"rt_pred::rt_pred(int dim, double* c, bool d){    assert(dim >= 0);    dimension = dim;    coord = c;    dealloc = d;}rt_pred::~rt_pred(){    clear();}voidrt_pred::clear(){    if (dealloc && coord != NULL) {	delete [] coord;    }    coord = NULL;    dealloc = false;}voidrt_pred::set(double* c, bool d){    clear();    coord = c;    dealloc = d;}boolrt_pred::isEqual(const rt_pred& p, int n) const{    if (dimension != p.dimension) {	return(false);    }    for (int i = 0; i < n; ++i) {	if (coord[i] != p.coord[i]) {	    return(false);	}    }    return(true);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -