1 package org.catacomb.numeric.difnet.model; 2 3 import org.catacomb.numeric.difnet.DiffusibleQuantity; 4 import org.catacomb.numeric.difnet.StructureNode; 5 6 7 public class BasicStructureNode implements StructureNode { 8 9 10 int iwork; 11 boolean fixed; 12 13 double capacitance; 14 15 double area; 16 17 double x; 18 double y; 19 double z; 20 double radius; 21 22 double initialValue; 23 24 25 26 27 public BasicStateNode newState() { 28 return new BasicStateNode(this); 29 } 30 31 public void setInitialValue(double d) { 32 initialValue = d; 33 } 34 35 public void setFixedValue(double d) { 36 initialValue = d; 37 fixed = true; 38 } 39 40 41 public double getInitialValue() { 42 return initialValue; 43 } 44 45 46 public void setPosition(double vx, double vy, double vz) { 47 x = vx; 48 y = vy; 49 z = vz; 50 } 51 52 public void setRadius(double r) { 53 radius = r; 54 } 55 56 double getX() { 57 return x; 58 } 59 60 double getY() { 61 return y; 62 } 63 64 double getZ() { 65 return z; 66 } 67 68 double getRadius() { 69 return radius; 70 } 71 72 73 public void setWork(int i) { 74 iwork = i; 75 } 76 77 78 public int getWork() { 79 return iwork; 80 } 81 82 83 public void setFixed(boolean b) { 84 fixed = b; 85 } 86 87 88 public boolean hasFixedValue(DiffusibleQuantity dq) { 89 return fixed; 90 } 91 92 public double getCapacitance() { 93 return capacitance; 94 } 95 96 public void setArea(double d) { 97 area = d; 98 } 99 100 public double getArea() { 101 return area; 102 } 103 104 public void incrementArea(double d) { 105 area += d; 106 } 107 108 } 109 110 111 112