int from_column, to_column;
+ private double mean;
+
/**
* update the bean with given values
*
* @param max
*/
public void update(int from_column, int to_column, int minPos,
- double min, int maxPos, double max)
+ double min, int maxPos, double max, double mean)
{
this.from_column = from_column;
this.to_column = to_column;
this.min = min;
this.maxPos = maxPos;
this.max = max;
+ this.mean = mean;
}
/**
}
/**
+ * @return the mean
+ */
+ public double getMean()
+ {
+ return mean;
+ }
+
+ /**
+ * @param mean
+ * the mean to set
+ */
+ public void setMean(double mean)
+ {
+ this.mean = mean;
+ }
+
+ /**
* @return the from_column
*/
public int getFrom_column()
public void testContactRangeBean()
{
ContactRange cr = new ContactRange();
- cr.update(5, 15, 6, 0.2, 12, 1.5);
+ cr.update(5, 15, 6, 0.2, 12, 1.5,3.7);
Assert.assertEquals(5, cr.getFrom_column());
Assert.assertEquals(15, cr.getTo_column());
Assert.assertEquals(6, cr.getMinPos());
Assert.assertEquals(0.2, cr.getMin());
Assert.assertEquals(12, cr.getMaxPos());
Assert.assertEquals(1.5, cr.getMax());
+ Assert.assertEquals(3.7, cr.getMean());
cr.setFrom_column(6);
Assert.assertEquals(6, cr.getFrom_column());
cr.setTo_column(16);
Assert.assertEquals(13, cr.getMaxPos());
cr.setMax(2.5);
Assert.assertEquals(2.5, cr.getMax());
+ cr.setMean(3.7);
+ Assert.assertEquals(3.7, cr.getMean());
}
}