Examples of TableFunctionMalformedException


Examples of unbbayes.prs.mebn.compiler.exception.TableFunctionMalformedException

      match('~');
    }

    ICompilerBooleanValue factor = bFactor();
    if (factor == null) {
      throw new TableFunctionMalformedException();
    }
    // Debug.println("EXITING NOT FACTOR");
   
    if (isNot) {
      return new CompilerNotValue(factor);
View Full Code Here

Examples of unbbayes.prs.mebn.compiler.exception.TableFunctionMalformedException

          Entity possibleValue = null;
          try {
            possibleValue = possibleStates.get(this.getNode().getPossibleValueIndex(this.noCaseChangeValue));
          } catch (Exception e) {
            //throw new TableFunctionMalformedException(e.getMessage());
            throw new TableFunctionMalformedException(e);
          }
          if (possibleValue == null) {
            throw new TableFunctionMalformedException();
          }
          declaredStates.add(possibleValue);
          currentCell.setPossibleValue(possibleValue);
        }
       
View Full Code Here

Examples of unbbayes.prs.mebn.compiler.exception.TableFunctionMalformedException

      nextChar();
  }

  /* Sends an alert telling that we expected some particular input */
  protected void expected(String error) throws TableFunctionMalformedException {
    throw new TableFunctionMalformedException("Error: " + error + " expected");
  }
View Full Code Here

Examples of unbbayes.prs.mebn.compiler.exception.TableFunctionMalformedException

//      } else if (this.value.equalsIgnoreCase("Exp")
//          || this.value.equalsIgnoreCase("Root")) {
//        return this.untranslatedFunction(this.noCaseChangeValue, 1);  // must be case-sensitive
      } else {
        // Debug.println("UNKNOWN FUNCTION FOUND: " + this.value);
        throw new TableFunctionMalformedException(this.getResource().getString("UnexpectedTokenFound")
            + ": " + value);
      }
    }
   
    // Debug.println("Function returning " + ret);
View Full Code Here

Examples of unbbayes.prs.mebn.compiler.exception.TableFunctionMalformedException

    // extract entity from mebn
    ObjectEntity entity = null;
    try {
      entity = this.getNode().getMFrag().getMultiEntityBayesianNetwork().getObjectEntityContainer().getObjectEntityByName(entityName);
    } catch (Exception e) {
      throw new TableFunctionMalformedException(e);
    }
    if (entity == null) {
      throw new TableFunctionMalformedException(entityName + " is not an Object Entity");
    }
   
    skipWhite();
    ret = new EntityCardinalityProbabilityValue(this.currentHeader, entity);
    match(')');
View Full Code Here

Examples of unbbayes.prs.mebn.compiler.exception.TableFunctionMalformedException

    } else {
      expected("Identifier");
   
    // assert this compiler is associated with an resident node
    if (getNode() == null) {
      throw new TableFunctionMalformedException("Node == null");
    }
    // check nodeName consistency: nodeName must be a parent
    boolean found = false;
    for (INode node : getNode().getParentNodes()) {
      try {
        if (node instanceof InputNode) {
          InputNode inputNode = (InputNode) node;
          if (inputNode.getResidentNodePointer().getResidentNode().getName().equals(nodeName)) {
            found = true;
            break;
          }
        }
        if (node.getName().equals(nodeName)) {
          found = true;
          break;
        }
      } catch (Exception e) {
        try {
          Debug.println(getClass(), e.getMessage(), e);
        } catch (Throwable t) {
          e.printStackTrace();
          t.printStackTrace();
        }
      }
    }
    if (!found) {
      throw new TableFunctionMalformedException(nodeName + " is not a parent of " + getNode());
    }
   
    skipWhite();
    return nodeName;
  }
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.