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

How to use
ATermAppl
in
openllet.aterm

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

origin: Galigator/openllet

@Override
public ATermAppl getTerm()
{
  return _hasValue ? (ATermAppl) _atermValue.getArgument(0) : null;
}
origin: Galigator/openllet

/**
 * To string
 */
@Override
public String toString()
{
  return _node.getName() + "[" + _label + "]";
}
origin: Galigator/openllet

public static boolean isComplexClass(final ATerm c)
{
  if (c instanceof ATermAppl)
  {
    final ATermAppl a = (ATermAppl) c;
    final AFun f = a.getAFun();
    return CLASS_FUN.contains(f);
  }
  return false;
}
origin: Galigator/openllet

public final static boolean isHasValue(final ATermAppl a)
{
  return SOMEFUN.equals(a.getAFun()) && VALUEFUN.equals(((ATermAppl) a.getArgument(1)).getAFun());
}
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: 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 AtomDObject convertAtomDObject(final ATermAppl t)
{
  if (ATermUtils.isVar(t))
    return new AtomDVariable(((ATermAppl) t.getArgument(0)).getName());
  else
    if (ATermUtils.isLiteral(t))
      return new AtomDConstant(t);
  throw new InternalReasonerException("Unrecognized term: " + t);
}
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

  _types[ATOM].remove(c);
else
  if (c.getAFun().equals(ATermUtils.ANDFUN))
    if (c.getAFun().equals(ATermUtils.ALLFUN))
      _types[ALL].remove(c);
    else
      if (c.getAFun().equals(ATermUtils.MINFUN))
        _types[MIN].remove(c);
      else
        if (c.getAFun().equals(ATermUtils.NOTFUN))
          final ATermAppl x = (ATermAppl) c.getArgument(0);
          if (ATermUtils.isAnd(x))
            _types[OR].remove(c);
                  _types[ATOM].remove(c);
                else
                  if (x.getArity() == 0)
                    _types[ATOM].remove(c);
                  else
          if (c.getAFun().equals(ATermUtils.VALUEFUN))
            _types[NOM].remove(c);
          else
origin: Galigator/openllet

if (1 != c.getArity())
  throw new OpenError("arity isn't 1.");
if (1 == c.getArity())
  final ATerm arg = c.getArgument(0);
  if (arg instanceof ATermList)
    for (final ATerm term : (ATermList) arg)
  for (final ATerm term : c.getArgumentArray())
    terms = retrieve((ATermAppl) term, terms);
origin: Galigator/openllet

final AFun fun = arg.getAFun();
final Integer key = _applSignatures.get(fun);
if (key == null)
  if (arg.isQuoted())
    header = (byte) (header | APPLQUOTED);
  _currentBuffer.put(header);
  writeInt(arg.getArity());
origin: Galigator/openllet

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

@Override
public RestrictedDatatype<ATermAppl> applyConstrainingFacet(final ATermAppl facet, final Object value) throws InvalidConstrainingFacetException
  final String name = facet.getName().substring(BuiltinNamespace.XSD.getURI().length());
      final ATermAppl payload = (ATermAppl) term.getChildAt(0); // The 'pattern'.
      final Pattern pattern = Pattern.compile(payload.getName());
      return new RestrictedTextDatatype(_dt, _check.and(str -> pattern.matcher(str).matches()), _allowLang, _excludedValues);
      throw new UnsupportedOperationException(facet.getName() + " is an unknow restriction");
origin: Galigator/openllet

if (_fun.equals(appl.getAFun()))
  return matchArguments(appl.getArgumentArray(), list);
return false;
  final AFun afun = appl.getAFun();
  if (afun.getName().equals("appl") && !afun.isQuoted())
    return matchArguments(appl.getArgumentArray(), list);
        return matchArguments(appl.getArgumentArray(), list);
          return matchArguments(appl.getArgumentArray(), list);
            return matchArguments(appl.getArgumentArray(), list);
origin: Galigator/openllet

private static AtomDObject convertAtomDObject(final ATermAppl t)
{
  if (ATermUtils.isVar(t))
    return new AtomDVariable(((ATermAppl) t.getArgument(0)).getName());
  else
    if (ATermUtils.isLiteral(t))
      return new AtomDConstant(t);
  throw new InternalReasonerException("Unrecognized term: " + t);
}
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

  _types[ATOM].remove(c);
else
  if (c.getAFun().equals(ATermUtils.ANDFUN))
    if (c.getAFun().equals(ATermUtils.ALLFUN))
      _types[ALL].remove(c);
    else
      if (c.getAFun().equals(ATermUtils.MINFUN))
        _types[MIN].remove(c);
      else
        if (c.getAFun().equals(ATermUtils.NOTFUN))
          final ATermAppl x = (ATermAppl) c.getArgument(0);
          if (ATermUtils.isAnd(x))
            _types[OR].remove(c);
                  _types[ATOM].remove(c);
                else
                  if (x.getArity() == 0)
                    _types[ATOM].remove(c);
                  else
          if (c.getAFun().equals(ATermUtils.VALUEFUN))
            _types[NOM].remove(c);
          else
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

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

if (1 != c.getArity())
  throw new OpenError("arity isn't 1.");
if (1 == c.getArity())
  final ATerm arg = c.getArgument(0);
  if (arg instanceof ATermList)
    for (final ATerm term : (ATermList) arg)
  for (final ATerm term : c.getArgumentArray())
    terms = retrieve((ATermAppl) term, terms);
openllet.atermATermAppl

Javadoc

An ATermAppl represents a function application.

Most used methods

  • getArgument
  • getName
  • getAFun
  • getArity
  • 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.
  • setArgument

Popular in Java

  • Making http post requests using okhttp
  • getSupportFragmentManager (FragmentActivity)
  • findViewById (Activity)
  • setScale (BigDecimal)
  • Rectangle (java.awt)
    A Rectangle specifies an area in a coordinate space that is enclosed by the Rectangle object's top-
  • Socket (java.net)
    Provides a client-side TCP socket.
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • HashSet (java.util)
    HashSet is an implementation of a Set. All optional operations (adding and removing) are supported.
  • TimeUnit (java.util.concurrent)
    A TimeUnit represents time durations at a given unit of granularity and provides utility methods to
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Top plugins for WebStorm
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