1 | /* |
2 | * Copyright 2004-2014 H2 Group. Multiple-Licensed under the MPL 2.0, |
3 | * and the EPL 1.0 (http://h2database.com/html/license.html). |
4 | * Initial Developer: H2 Group |
5 | */ |
6 | package org.h2.table; |
7 | |
8 | import org.h2.index.Index; |
9 | |
10 | /** |
11 | * The plan item describes the index to be used, and the estimated cost when |
12 | * using it. |
13 | */ |
14 | public class PlanItem { |
15 | |
16 | /** |
17 | * The cost. |
18 | */ |
19 | double cost; |
20 | |
21 | private Index index; |
22 | private PlanItem joinPlan; |
23 | private PlanItem nestedJoinPlan; |
24 | |
25 | void setIndex(Index index) { |
26 | this.index = index; |
27 | } |
28 | |
29 | public Index getIndex() { |
30 | return index; |
31 | } |
32 | |
33 | PlanItem getJoinPlan() { |
34 | return joinPlan; |
35 | } |
36 | |
37 | PlanItem getNestedJoinPlan() { |
38 | return nestedJoinPlan; |
39 | } |
40 | |
41 | void setJoinPlan(PlanItem joinPlan) { |
42 | this.joinPlan = joinPlan; |
43 | } |
44 | |
45 | void setNestedJoinPlan(PlanItem nestedJoinPlan) { |
46 | this.nestedJoinPlan = nestedJoinPlan; |
47 | } |
48 | |
49 | } |