Tabnine Logo
ATermAppl.getArity
Code IndexAdd Tabnine to your IDE (free)

How to use
getArity
method
in
openllet.aterm.ATermAppl

Best Java code snippets using openllet.aterm.ATermAppl.getArity (Showing top 20 results out of 315)

origin: Galigator/openllet

@Override
public boolean isAnon()
{
  return _name.getArity() != 0;
}
origin: Galigator/openllet

@Override
public boolean isAnon()
{
  return _name.getArity() != 0;
}
origin: Galigator/openllet

public static final boolean isPrimitive(final ATermAppl c)
{
  return c.getArity() == 0;
}
origin: Galigator/openllet

public static final boolean isPrimitive(final ATermAppl c)
{
  return c.getArity() == 0;
}
origin: Galigator/openllet

NamedDatatype(final ATermAppl name, final RestrictedDatatype<T> range)
{
  if (name == null)
    throw new NullPointerException();
  if (name.getArity() != 0)
    throw new IllegalArgumentException();
  _name = name;
  _range = range;
}
origin: Galigator/openllet

NamedDatatype(final ATermAppl name, final RestrictedDatatype<T> range)
{
  if (name == null)
    throw new NullPointerException();
  if (name.getArity() != 0)
    throw new IllegalArgumentException();
  _name = name;
  _range = range;
}
origin: Galigator/openllet

protected AbstractBaseDatatype(final ATermAppl name)
{
  if (name == null)
    throw new NullPointerException();
  if (name.getArity() != 0)
    throw new IllegalArgumentException();
  this._name = name;
  this._hashCode = name.hashCode();
}
origin: Galigator/openllet

protected AbstractBaseDatatype(final ATermAppl name)
{
  if (name == null)
    throw new NullPointerException();
  if (name.getArity() != 0)
    throw new IllegalArgumentException();
  this._name = name;
  this._hashCode = name.hashCode();
}
origin: com.github.galigator.openllet/openllet-owlapi

private static IRI iri(final ATermAppl term)
{
  if (term.getArity() != 0)
    throw new OWLRuntimeException("Trying to convert an anonymous term " + term);
  return IRI.create(term.getName());
}
origin: Galigator/openllet

private static IRI iri(final ATermAppl term)
{
  if (term.getArity() != 0)
    throw new OWLRuntimeException("Trying to convert an anonymous term " + term);
  return IRI.create(term.getName());
}
origin: Galigator/openllet

private static IRI iri(final ATermAppl term)
{
  if (term.getArity() != 0)
    throw new OWLRuntimeException("Trying to convert an anonymous term " + term);
  return IRI.create(term.getName());
}
origin: Galigator/openllet

@Override
public void visitHasValue(final ATermAppl term)
{
  _out.print("(");
  visit((ATermAppl) term.getArgument(0));
  _out.print(" value ");
  final ATermAppl value = (ATermAppl) ((ATermAppl) term.getArgument(1)).getArgument(0);
  if (value.getArity() == 0)
    visitTerm(value);
  else
    visitLiteral(value);
  _out.print(")");
}
origin: Galigator/openllet

@Override
public void visitHasValue(final ATermAppl term)
{
  _out.print("(");
  visit((ATermAppl) term.getArgument(0));
  _out.print(" value ");
  final ATermAppl value = (ATermAppl) ((ATermAppl) term.getArgument(1)).getArgument(0);
  if (value.getArity() == 0)
    visitTerm(value);
  else
    visitLiteral(value);
  _out.print(")");
}
origin: Galigator/openllet

@Override
public void validateTypes(final Individual node, final List<ATermAppl> negatedTypes)
{
  for (int i = 0, n = negatedTypes.size(); i < n; i++)
  {
    final ATermAppl a = negatedTypes.get(i);
    if (a.getArity() == 0)
      continue;
    final ATermAppl notA = (ATermAppl) a.getArgument(0);
    if (node.hasType(notA))
    {
      if (!node.hasType(a))
        throw new InternalReasonerException("Invalid type found: " + node + " " + " " + a + " " + node.debugString() + " " + node._depends);
      throw new InternalReasonerException("Clash found: " + node + " " + a + " " + node.debugString() + " " + node._depends);
    }
  }
}
origin: Galigator/openllet

@Override
public void validateTypes(final Individual node, final List<ATermAppl> negatedTypes)
{
  for (int i = 0, n = negatedTypes.size(); i < n; i++)
  {
    final ATermAppl a = negatedTypes.get(i);
    if (a.getArity() == 0)
      continue;
    final ATermAppl notA = (ATermAppl) a.getArgument(0);
    if (node.hasType(notA))
    {
      if (!node.hasType(a))
        throw new InternalReasonerException("Invalid type found: " + node + " " + " " + a + " " + node.debugString() + " " + node._depends);
      throw new InternalReasonerException("Clash found: " + node + " " + a + " " + node.debugString() + " " + node._depends);
    }
  }
}
origin: Galigator/openllet

static public Node makeGraphResource(final ATermAppl term)
{
  if (ATermUtils.isBnode(term))
    return NodeFactory.createBlankNode(new BlankNodeId(((ATermAppl) term.getArgument(0)).getName()));
  else
    if (term.equals(ATermUtils.TOP))
      return OWL.Thing.asNode();
    else
      if (term.equals(ATermUtils.BOTTOM))
        return OWL.Nothing.asNode();
      else
        if (term.equals(ATermUtils.TOP_DATA_PROPERTY))
          return OWL2.topDataProperty.asNode();
        else
          if (term.equals(ATermUtils.BOTTOM_DATA_PROPERTY))
            return OWL2.bottomDataProperty.asNode();
          else
            if (term.equals(ATermUtils.TOP_OBJECT_PROPERTY))
              return OWL2.topObjectProperty.asNode();
            else
              if (term.equals(ATermUtils.BOTTOM_OBJECT_PROPERTY))
                return OWL2.bottomObjectProperty.asNode();
              else
                if (term.getArity() == 0)
                  return NodeFactory.createURI(term.getName());
  //		if (term.getName().equals(ATermUtils.INVFUN.getName()))
  //			return OWL.inverseOf.asNode(); //	term.getArgument(0); // XXX Que devient le parametre ?
  PelletReasoner._logger.warning("Term " + term + " can't be convert into Node");
  return null;
}
origin: com.github.galigator.openllet/openllet-jena

static public Node makeGraphResource(final ATermAppl term)
{
  if (ATermUtils.isBnode(term))
    return NodeFactory.createBlankNode(new BlankNodeId(((ATermAppl) term.getArgument(0)).getName()));
  else
    if (term.equals(ATermUtils.TOP))
      return OWL.Thing.asNode();
    else
      if (term.equals(ATermUtils.BOTTOM))
        return OWL.Nothing.asNode();
      else
        if (term.equals(ATermUtils.TOP_DATA_PROPERTY))
          return OWL2.topDataProperty.asNode();
        else
          if (term.equals(ATermUtils.BOTTOM_DATA_PROPERTY))
            return OWL2.bottomDataProperty.asNode();
          else
            if (term.equals(ATermUtils.TOP_OBJECT_PROPERTY))
              return OWL2.topObjectProperty.asNode();
            else
              if (term.equals(ATermUtils.BOTTOM_OBJECT_PROPERTY))
                return OWL2.bottomObjectProperty.asNode();
              else
                if (term.getArity() == 0)
                  return NodeFactory.createURI(term.getName());
  //		if (term.getName().equals(ATermUtils.INVFUN.getName()))
  //			return OWL.inverseOf.asNode(); //	term.getArgument(0); // XXX Que devient le parametre ?
  PelletReasoner._logger.warning("Term " + term + " can't be convert into Node");
  return null;
}
origin: Galigator/openllet

static public Node makeGraphResource(final ATermAppl term)
{
  if (ATermUtils.isBnode(term))
    return NodeFactory.createBlankNode(new BlankNodeId(((ATermAppl) term.getArgument(0)).getName()));
  else
    if (term.equals(ATermUtils.TOP))
      return OWL.Thing.asNode();
    else
      if (term.equals(ATermUtils.BOTTOM))
        return OWL.Nothing.asNode();
      else
        if (term.equals(ATermUtils.TOP_DATA_PROPERTY))
          return OWL2.topDataProperty.asNode();
        else
          if (term.equals(ATermUtils.BOTTOM_DATA_PROPERTY))
            return OWL2.bottomDataProperty.asNode();
          else
            if (term.equals(ATermUtils.TOP_OBJECT_PROPERTY))
              return OWL2.topObjectProperty.asNode();
            else
              if (term.equals(ATermUtils.BOTTOM_OBJECT_PROPERTY))
                return OWL2.bottomObjectProperty.asNode();
              else
                if (term.getArity() == 0)
                  return NodeFactory.createURI(term.getName());
  //		if (term.getName().equals(ATermUtils.INVFUN.getName()))
  //			return OWL.inverseOf.asNode(); //	term.getArgument(0); // XXX Que devient le parametre ?
  PelletReasoner._logger.warning("Term " + term + " can't be convert into Node");
  return null;
}
origin: Galigator/openllet

private boolean absorbII(final Set<ATermAppl> set)
{
  for (final ATermAppl term : set)
  {
    final TermDefinition td = _tbox._Tu.getTD(term);
    boolean canAbsorb;
    if (td != null)
      canAbsorb = td.getEqClassAxioms().isEmpty();
    else
      canAbsorb = term.getArity() == 0 && set.size() > 1;
    if (canAbsorb)
    {
      set.remove(term);
      final ATermList setlist = ATermUtils.makeList(set);
      ATermAppl conjunct = ATermUtils.makeAnd(setlist);
      conjunct = ATermUtils.makeNot(conjunct);
      final ATermAppl sub = ATermUtils.makeSub(term, ATermUtils.nnf(conjunct));
      _tbox._Tu.addDef(sub);
      _subLogger.fine(() -> "Absorb named: " + ATermUtils.toString(sub));
      _tbox.addAxiomExplanation(sub, _explanation);
      return true;
    }
  }
  return false;
}
origin: Galigator/openllet

private boolean absorbII(final Set<ATermAppl> set)
{
  for (final ATermAppl term : set)
  {
    final TermDefinition td = _tbox._Tu.getTD(term);
    boolean canAbsorb;
    if (td != null)
      canAbsorb = td.getEqClassAxioms().isEmpty();
    else
      canAbsorb = term.getArity() == 0 && set.size() > 1;
    if (canAbsorb)
    {
      set.remove(term);
      final ATermList setlist = ATermUtils.makeList(set);
      ATermAppl conjunct = ATermUtils.makeAnd(setlist);
      conjunct = ATermUtils.makeNot(conjunct);
      final ATermAppl sub = ATermUtils.makeSub(term, ATermUtils.nnf(conjunct));
      _tbox._Tu.addDef(sub);
      _subLogger.fine(() -> "Absorb named: " + ATermUtils.toString(sub));
      _tbox.addAxiomExplanation(sub, _explanation);
      return true;
    }
  }
  return false;
}
openllet.atermATermApplgetArity

Javadoc

Gets the arity of this application. Arity is the number of arguments of a function application.

Popular methods of ATermAppl

  • getArgument
  • getName
  • getAFun
  • getArgumentArray
    Gets the arguments of this application as an array of ATerm objects.
  • getChildAt
  • getArguments
    Gets the arguments of this application.
  • getType
  • isEqual
  • isQuoted
    Checks if this application is quoted. A quoted application looks like this: "foo", whereas an unquot
  • setArgument
    Sets a specific argument of this application.

Popular in Java

  • Making http requests using okhttp
  • onCreateOptionsMenu (Activity)
  • scheduleAtFixedRate (ScheduledExecutorService)
  • notifyDataSetChanged (ArrayAdapter)
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • SecureRandom (java.security)
    This class generates cryptographically secure pseudo-random numbers. It is best to invoke SecureRand
  • Time (java.sql)
    Java representation of an SQL TIME value. Provides utilities to format and parse the time's represen
  • Collection (java.util)
    Collection is the root of the collection hierarchy. It defines operations on data collections and t
  • TimerTask (java.util)
    The TimerTask class represents a task to run at a specified time. The task may be run once or repeat
  • JComboBox (javax.swing)
  • Best plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now