Ejemplo n.º 1
0
 /*
  * We have no way of anticipating the return types of built-ins in rules so we need to perform a runtime check.
  */
 public C(BA ba) {
   if (ba instanceof C) {
     C c = (C) ba;
     this.id = c.getid();
   } else
     throw new TargetSWRLRuleEngineInternalException(
         "expecting OWL named class from bound built-in argument, got "
             + ba.getClass().getCanonicalName());
 }
Ejemplo n.º 2
0
  /*
   * We have no way of anticipating the return types of built-ins in rules so we need to perform a runtime check.
   */
  public AP(@NonNull BA ba) {
    super("<InProcess>");

    if (ba instanceof AP) {
      AP p = (AP) ba;
      this.setPEID(p.getid());
    } else
      throw new TargetSWRLRuleEngineInternalException(
          "expecting OWL annotation property from bound built-in argument, got "
              + ba.getClass().getCanonicalName());
  }