1 package org.simantics.document.server;
3 import org.simantics.databoard.binding.Binding;
4 import org.simantics.db.ReadGraph;
5 import org.simantics.db.exception.DatabaseException;
6 import org.simantics.db.layer0.variable.ConstantPropertyVariable;
7 import org.simantics.db.layer0.variable.Variable;
9 public class PrimitiveValueVariable extends ConstantPropertyVariable {
11 final private Variable property;
13 public PrimitiveValueVariable(Variable parent, String name, Variable property) {
14 super(parent, name, null, null);
15 this.property = property;
19 public <T> T getValue(ReadGraph graph) throws DatabaseException {
20 return property.getValue(graph);
24 public <T> T getValue(ReadGraph graph, Binding binding) throws DatabaseException {
25 return property.getValue(graph, binding);