Package infosapient.system

Examples of infosapient.system.FSEvent


  public FzyRule addConsequent(FzyConsequent fc) {
    try {
      throw new FzySystemException(this +
      " Consequents may NOT be given to an Unconditional Rule");
    } catch (FzySystemException fse) {
      notifyObservers(new FSEvent(this, "Error", fse));
    }
    return this;
  }
View Full Code Here


public double farEdge(FzySet fset) {
  try {
    findPlateau(fset);
    setDomainValue(getScalarUsing(fset, getRightEdge()));
  } catch (Exception e) {
    notifyObservers(new FSEvent(this, "Error", e));
  } finally {
    return getDomainValue();
  }
}
View Full Code Here

  double range=fset.getHighDomain() - fset.getLowDomain();
  double domainValue=fset.getLowDomain()+(inx * range)/(VECMAX-1);
  return domainValue;
  }
  protected void issueWarning(FzySet fset,double height,int pCount){
  notifyObservers(new FSEvent(this, "Warning", "CAUTION: Solution Fuzzy Set '"
        + fset.getName()
        + "' has "
        + Integer.toString(pCount)
        + " plateau(s) at height: "
        + Double.toString(height)
View Full Code Here

  */
  public double resolveToScalar(FzySet aSet) {
  double integratedMem = aSet.integrateMbr();
  if (integratedMem == 0) {
    setChanged();
    notifyObservers(new FSEvent(this, "Warning", getName() + " method not performed as fset membership is zero."));
    return 0.0;
  }else{
    return resolveUsing(aSet);
  }
  }
View Full Code Here

          ruleText);
          theRule = ruleCompiler.compileRule();
         
          if (getController().getKB().containsRule(theRule.getName()))
            getController().getKB().removeRule(theRule);
          FSEvent fse = new FSEvent(this, "RULE:created", theRule);
          theRule.addObserver(controller.getKB());
          reo.notify(fse);
          this.setEnabled(false);
          newAction.setEnabled(true);
        } catch (Exception pe) {
View Full Code Here

    x = (lDomain[i] * lMember[i]) + x;
    }
    try {
    resultant = x / y;
    } catch (ArithmeticException ae) {
    notifyObservers(new FSEvent(this, "Error", ae));
    }
    try {
    fset.setSolution(resultant);
    if (DEBUG_[2]) trace[2].println(" Resolved value for set: "
                + fset.getQualifiedName()
                +" is: " + fset.getSolution()
                +", with degree of membership " + fset.getSolutionDOM());
    } catch (Exception iae) {
    notifyObservers(new FSEvent(this, "Error", iae));
    }
  } else {
    if (DEBUG_[2]) trace[2].println(
    " ***WARNING**** Centroid method not performed as fset membership not normalized.");
  }
View Full Code Here

  public void updateKBReasoningMethods() {
    getKB().setRunBefore(runBefore);
    getKB().setResolutionMethod((infosapient.resolution.FzyResolutionMethod)reslvMethodsLst.getSelectedValue());
    getKB().setImplicationMethod((infosapient.resolution.FzyImplicationMethod)inferMethodsLst.getSelectedValue());
    getKB().setCorrelationMethod((infosapient.resolution.FzyCorrelation)corrMethodsLst.getSelectedValue());
    getKB().notifyObservers(new FSEvent(this, "KB:InferMethodsSet", getKB()));

  }
View Full Code Here

            public void mouseClicked(MouseEvent e) {
                attrItemSelected(attributeList.getSelectedValue());
                //System.err.println("Mouse clicks from attrib list: " + e.getClickCount());
                if (e.getClickCount() >= 2) {
                    getController().handleFSEvent(
                        new FSEvent(
                            this,
                            "editAttrib",
                            (FzyAttribute) attributeList.getSelectedValue()));
                }
            }
View Full Code Here

        }
    }
    protected void ruleItemSelected(Object iSelect) {
        setMenuItem.setEnabled(false);
        if (iSelect instanceof FzyRule)
            getController().handleFSEvent(new FSEvent(this, "editRule", iSelect));
    }
View Full Code Here

        if (iSelect instanceof FzyRule)
            getController().handleFSEvent(new FSEvent(this, "editRule", iSelect));
    }
    protected void setItemSelected(Object iSelect) {
        if (theAttribute != null)
            getController().handleFSEvent(new FSEvent(this, "editSet", (FzySet) iSelect));
    }
View Full Code Here

TOP

Related Classes of infosapient.system.FSEvent

Copyright © 2018 www.massapicom. 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.