rendered paste body/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package org.sunspotworld;
import java.util.List;
/**
*
* @author Antonio Garcia and Andrew Hall
*/
public class DigitalDisplay {
private double min;
private double max;
private double delta;
private List<String> colors;
String poop;
public void setUpDisplay(){
}
public boolean showDisplay(double val){
if(!inBounds(val)){
return false;
}
int steps = round((val - min)/delta);
return true;
}
public boolean inBounds(double val){
return ((val <= max) && (val >= min));
}
private int round(double val){
return ((val - Math.floor(val)< 0.5) ? (int) val : (int) val +1);
}
}