
package de.ivu.elect.jee.presentation.dynamicform;

public class ReadOnlyDoubleProperty extends AbstractDoubleProperty {

  private final String label;

  private final Double value;

  public ReadOnlyDoubleProperty(String label, Double value) {
    super();

    this.label = label;
    this.value = value;
  }

  @Override
  public boolean isReadonly() {
    return true;
  }

  @Override
  public boolean getDefaultRequired() {
    return false;
  }

  @Override
  public String getDefaultLabel() {
    return label;
  }

  @Override
  public Double getValue() {
    return value;
  }

  @Override
  public void setValue(Double value) {
    // Readonly!
  }
}
