cut_info.java

来自「用java语言实现的rtree空间索引技术」· Java 代码 · 共 48 行

JAVA
48
字号
/*
	COMP 630C project
	Re-implementation of R+ tree

	Group member:
	Cheng Wing Hang, Nelson
	Cheung Kwok Ho, Steven
	Ngai Ming Wai, Ryan
	Shiu Hoi Nam
	Tsui Chi Man
*/

import java.*;

// Storing the information after calculation of how to split
// the node and its cost
public class Cut_info {

	float   cost;   // Partition cost.
	float   cut;    // Point where partition takes place.
	LIST	S1, S2 ;
	char	dir;


        public Cut_info()
        {
        }

   // constructor
	public Cut_info(float cost, float cut) {
		this.cost = cost;
		this.cut = cut;
	}

   // constructor
	public Cut_info(float cost, float cut, CELL C1, CELL C2) {
		this.cost = cost;
		this.cut = cut;
		S1 = new LIST(C1);
		S2 = new LIST(C2);
	}

   // print where the cut takes place and its cost
	public void print() {
		System.out.println("Cost: " + this.cost + ", cut: " + this.cut);
	}
}

⌨️ 快捷键说明

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