Codota Logo
OntopBindingSet
Code IndexAdd Codota to your IDE (free)

How to use
OntopBindingSet
in
it.unibz.inf.ontop.answering.resultset

Best Java code snippets using it.unibz.inf.ontop.answering.resultset.OntopBindingSet (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ArrayList a =
  • Codota Iconnew ArrayList<String>()
  • Codota Iconnew ArrayList()
  • Codota Iconnew ArrayList<Object>()
  • Smart code suggestions by Codota
}
origin: ontop/ontop

@Override
public List<String> getBindingNames() throws OWLException {
  return ontopBindingSet.getBindingNames();
}
origin: ontop/ontop

@Override
@Nonnull
public Iterator<Binding> iterator() {
  return ontopBindingSet.getBindings()
      .map(this::convertBinding)
      .iterator();
}
origin: it.unibz.inf.ontop/ontop-rdf4j

@Override
@Nonnull
public Iterator<Binding> iterator() {
  List<Binding> allBindings = new LinkedList<>();
  List<String> names = ontopBindingSet.getBindingNames();
  for (String s : names) {
    if (ontopBindingSet.hasBinding(s)) {
      allBindings.add(getBinding(s));
    }
  }
  return allBindings.iterator();
}
origin: ontop/ontop

@Override
@Nullable
public Value getValue(String variableName) {
  try {
    final Constant constant = ontopBindingSet.getConstant(variableName);
    return constant == null?
        null:
        RDF4JHelper.getValue(constant);
  } catch (OntopResultConversionException e) {
    throw new RuntimeException(e);
  }
}
origin: ontop/ontop

@Override
@Nullable
public Binding getBinding(String bindingName) {
  OntopBinding ontopBinding = ontopBindingSet.getBinding(bindingName);
  return ontopBinding == null?
      null:
      convertBinding(ontopBinding);
}
origin: ontop/ontop

/** Inefficient */
@Override
public boolean hasBinding(String bindingName) {
  return ontopBindingSet.hasBinding(bindingName);
}
origin: ontop/ontop

@Override
@Nonnull
public Iterator<OWLBinding> iterator() {
  return Iterators.transform(ontopBindingSet.iterator(), OntopOWLBinding::new);
}
origin: it.unibz.inf.ontop/ontop-rdf4j

@Override
@Nullable
public Value getValue(String bindingName) {
  if (!hasBinding(bindingName)) {
    return null;
  } else {
    try {
      final Constant constant = ontopBindingSet.getConstant(bindingName);
      return RDF4JHelper.getValue(constant);
    } catch (OntopResultConversionException e) {
      throw new RuntimeException(e);
    }
  }
}
origin: ontop/ontop

@Override
public OWLBinding getBinding(String bindingName) throws OWLException {
  final OntopBinding ontopBinding = ontopBindingSet.getBinding(bindingName);
  if (ontopBinding == null) {
    return null;
  } else {
    return new OntopOWLBinding(ontopBinding);
  }
}
origin: it.unibz.inf.ontop/ontop-rdf4j

@Override
public boolean hasBinding(String bindingName) {
  return ontopBindingSet.hasBinding(bindingName);
}
origin: ontop/ontop

@Override
public OWLNamedIndividual getOWLNamedIndividual(int column) throws OWLException {
  try {
    return (OWLNamedIndividual) translate(ontopBindingSet.getConstant(column));
  } catch (Exception e) {
    throw new OntopOWLException(e);
  }
}
origin: it.unibz.inf.ontop/ontop-rdf4j

@Override
public Set<String> getBindingNames() {
  return new LinkedHashSet<>(ontopBindingSet.getBindingNames());
}
origin: ontop/ontop

@Override
public OWLIndividual getOWLIndividual(int column) throws OWLException {
  try {
    return (OWLIndividual) translate(ontopBindingSet.getConstant(column));
  } catch (Exception e) {
    throw new OntopOWLException(e);
  }
}
origin: ontop/ontop

@Override
public Set<String> getBindingNames() {
  return new LinkedHashSet<>(ontopBindingSet.getBindingNames());
}
origin: ontop/ontop

@Override
public OWLObject getOWLObject(int column) throws OWLException {
  try {
    return translate(ontopBindingSet.getConstant(column));
  } catch (Exception e) {
    throw new OntopOWLException(e);
  }
}
origin: ontop/ontop

@Override
public int size() {
  return ontopBindingSet.getBindingNames().size();
}
origin: ontop/ontop

@Override
public OWLObject getOWLObject(String column) throws OWLException {
  try {
    return translate(ontopBindingSet.getConstant(column));
  } catch (Exception e) {
    throw new OntopOWLException(e);
  }
}
origin: it.unibz.inf.ontop/ontop-rdf4j

@Override
public int size() {
  return ontopBindingSet.getBindingNames().size();
}
origin: ontop/ontop

@Override
public OWLLiteral getOWLLiteral(int column) throws OWLException {
  try {
    return (OWLLiteral) translate(ontopBindingSet.getConstant(column));
  } catch (Exception e) {
    throw new OntopOWLException(e);
  }
}
origin: ontop/ontop

@Override
public OWLIndividual getOWLIndividual(String column) throws OWLException {
  try {
    return (OWLIndividual) translate(ontopBindingSet.getConstant(column));
  } catch (Exception e) {
    throw new OntopOWLException(e);
  }
}
it.unibz.inf.ontop.answering.resultsetOntopBindingSet

Most used methods

  • getConstant
  • getBinding
    If all bindings are needed, less efficient than getBindings() or the iterator
  • getBindingNames
  • getBindings
  • hasBinding
  • iterator

Popular in Java

  • Creating JSON documents from java classes using gson
  • scheduleAtFixedRate (Timer)
  • getExternalFilesDir (Context)
  • putExtra (Intent)
  • PrintStream (java.io)
    A PrintStream adds functionality to another output stream, namely the ability to print representatio
  • BitSet (java.util)
    This class implements a vector of bits that grows as needed. Each component of the bit set has a boo
  • Deque (java.util)
    A linear collection that supports element insertion and removal at both ends. The name deque is shor
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • CountDownLatch (java.util.concurrent)
    A synchronization aid that allows one or more threads to wait until a set of operations being perfor
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now