package dkohl.bayes.probability;

public class ProbabilityAssignment extends Assignment {

	private double probability;

	public ProbabilityAssignment(Variable variable, String value,
			double probability) {
		super(variable, value);
		this.probability = probability;
	}

	public double getProbability() {
		return probability;
	}

	@Override
	public String toString() {
		StringBuilder sb = new StringBuilder();
		sb.append("(");
		sb.append(super.toString());
		sb.append(") ");
		sb.append(probability);
		return sb.toString();
	}
}
