org.diirt.datasource.graphene.VStringToStringReadFunction Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of datasource-graphene Show documentation
Show all versions of datasource-graphene Show documentation
Support for real-time graph rendering with graphene.
/**
* Copyright (C) 2010-14 diirt developers. See COPYRIGHT.TXT
* All rights reserved. Use is subject to license terms. See LICENSE.TXT
*/
package org.diirt.datasource.graphene;
import org.diirt.datasource.ReadFunction;
import org.diirt.vtype.VString;
/**
*
* @author carcassi
*/
public class VStringToStringReadFunction implements ReadFunction {
private final ReadFunction function;
public VStringToStringReadFunction(ReadFunction function) {
this.function = function;
}
@Override
public String readValue() {
VString value = function.readValue();
if (value == null) {
return null;
} else {
return value.getValue();
}
}
}