private String dereference(Object constantOrVarref) {
        if (constantOrVarref instanceof OperatorNode<?> varref) {
            Preconditions.checkState(userQuery != null,
                                     "properties must be available when trying to fetch user input");
            return userQuery.properties().getString(varref.getArgument(0, String.class));
        }
        else {
            return constantOrVarref.toString();
        }
    }
The YQL query language.

This class <em>must</em> be kept in lockstep with {@link VespaSerializer}.
Adding anything here will usually require a corresponding addition in
VespaSerializer.

@author Steinar Knutsen
@author Stian Kristoffersen
@author Simon Thoresen Hult
container-search/src/main/java/com/yahoo/search/yql/YqlParser.java