KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tctest > performance > sampledata > OrganicObjectGraphNode_52


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
3  */

4 package com.tctest.performance.sampledata;
5
6 public final class OrganicObjectGraphNode_52 extends OrganicObjectGraph {
7
8   private int size = 1;
9   private int[] types = new int[] { 3 };
10
11   private double f0;
12
13   public OrganicObjectGraphNode_52(int sequenceNumber, String JavaDoc envKey) {
14     super(sequenceNumber, envKey);
15   }
16
17   public OrganicObjectGraphNode_52() {
18     super();
19   }
20
21   protected int getSize() {
22     return size;
23   }
24
25   protected int getType(int index) {
26     return types[index];
27   }
28
29   protected void setValue(int index, double value) {
30     switch (index) {
31       case 0:
32         f0 = value;
33       default:
34         break;
35     }
36   }
37
38   public boolean equals(Object JavaDoc rawObj) {
39     if (!(rawObj instanceof OrganicObjectGraphNode_52)) { System.out.println("not instanceof"); System.out.println(rawObj.getClass().getName() + "=OrganicObjectGraphNode_52"); return false; }
40     OrganicObjectGraphNode_52 obj = (OrganicObjectGraphNode_52) rawObj;
41     if (f0 != obj.f0) return false;
42     return super.equals(obj);
43   }
44 }
45
Popular Tags