Examples of AtomDConstant


Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

    key.accept( visitor );
    return visitor.getData();
  }
 
  public Literal set( AtomDVariable key, ATermAppl value ) {
    AtomDConstant constant = new AtomDConstant( value );
    DataValueCollector collector = new DataValueCollector();
    constant.accept( collector );
    return set( key, collector.getValue() );
  }
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

        return null;
      }
      return new AtomDVariable( name.toString() );
    }
    else {
      return new AtomDConstant( node2term( node ) );
    }
  }
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

  private AtomDObject convertAtomDObject(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 );
 
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

  }

 
  public void visit(SWRLLiteralArgument cons) {
    cons.getLiteral().accept( this );
    swrlDObject = new AtomDConstant( term );
  }
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

        ATermAppl filler = (ATermAppl) c.getArgument( 1 );
       
        if( filler.getAFun().equals( ATermUtils.VALUEFUN ) ) {
          ATermAppl nominal = (ATermAppl) filler.getArgument( 0 );
          if( kb.isDatatypeProperty( p ) ) {
            AtomDConstant arg = new AtomDConstant( nominal );
            RuleAtom atom = new DatavaluedPropertyAtom( p, var, arg );
            atoms.add(atom);
          }
          else {
            AtomIConstant arg = new AtomIConstant( nominal );
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

          ATermAppl facetRestriction = (ATermAppl) list.getFirst();       
          ATermAppl facet = (ATermAppl) facetRestriction.getArgument( 0 );       
          String builtin = FACETS.get( facet );
          if( builtin != null ) {         
            ATermAppl value = (ATermAppl) facetRestriction.getArgument( 1 );
            atoms.add( new BuiltInAtom( builtin, var, new AtomDConstant( value ) ) );
          }
          else {
            atoms.add( new DataRangeAtom( c, var ) );
            return;
          }
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

    swrlIObject = new AtomIConstant( term );
  }

  public void visit(SWRLAtomConstantObject cons) {
    cons.getConstant().accept( this );
    swrlDObject = new AtomDConstant( term );
  }
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

        return null;
      }
      return new AtomDVariable( name.toString() );
    }
    else {
      return new AtomDConstant( node2term( node ) );
    }
  }
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

    ATermAppl i = term( "i" );
    ATermAppl R = term( "R" );
    ATermAppl l = literal( "l" );
    AtomIVariable v = new AtomIVariable( "v" );
    AtomDConstant c = new AtomDConstant( l );

    kb.addIndividual( i );
    kb.addDatatypeProperty( R );
    kb.addPropertyValue( R, i, l );
View Full Code Here

Examples of com.clarkparsia.pellet.rules.model.AtomDConstant

      ATermAppl filler = (ATermAppl) c.getArgument( 1 );
     
      if( filler.getAFun().equals( ATermUtils.VALUEFUN ) ) {
        ATermAppl nominal = (ATermAppl) filler.getArgument( 0 );
        if( kb.isDatatypeProperty( p ) ) {
          AtomDConstant arg = new AtomDConstant( nominal );
          RuleAtom atom = new DatavaluedPropertyAtom( p, var, arg );
          atoms.add(atom);
        }
        else {
          AtomIConstant arg = new AtomIConstant( nominal );
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.