Examples of handles()


Examples of org.ocpsoft.rewrite.config.ConfigurationProvider.handles()

         Collection<ConfigurationProvider<?>> enriched = ServiceLoader.loadEnriched(providerType);
         if (enriched.size() == 1)
         {
            ConfigurationProvider provider = enriched.iterator().next();
            Object configurationContext = context.get(type);
            if (provider.handles(configurationContext))
            {
               Configuration config = provider.getConfiguration(configurationContext);
               if (config != null)
               {
                  for (Rule rule : config.getRules())
View Full Code Here

Examples of org.ocpsoft.rewrite.servlet.spi.RewriteResultHandler.handles()

                        int handlerCount = resultHandlers.size();
                        for (int i = 0; i < handlerCount; i++)
                        {
                           RewriteResultHandler handler = resultHandlers.get(i);
                           if (handler.handles(operation.getEvent()))
                              handler.handleResult(operation.getEvent());
                        }
                     }
                     catch (Exception e) {
                        throw new RewriteException("Failed to handle PhaseOperation [" + operation + "]", e);
View Full Code Here

Examples of weka.core.Capabilities.handles()

   
    // attribute
    result.enableAllAttributeDependencies();
    // with NominalToBinary we can also handle nominal attributes, but only
    // if the kernel can handle numeric attributes
    if (result.handles(Capability.NUMERIC_ATTRIBUTES))
      result.enable(Capability.NOMINAL_ATTRIBUTES);
    result.enable(Capability.MISSING_VALUES);
   
    // class
    result.disableAllClasses();
View Full Code Here

Examples of weka.core.Capabilities.handles()

    // attribute
    result.enableAllAttributeDependencies();
    // with NominalToBinary we can also handle nominal attributes, but only
    // if the kernel can handle numeric attributes
    if (result.handles(Capability.NUMERIC_ATTRIBUTES))
      result.enable(Capability.NOMINAL_ATTRIBUTES);
    result.enable(Capability.MISSING_VALUES);
   
    // class
    result.disableAllClasses();
View Full Code Here

Examples of weka.core.Capabilities.handles()

    // attribute
    result.enableAllAttributeDependencies();
    // with NominalToBinary we can also handle nominal attributes, but only
    // if the kernel can handle numeric attributes
    if (result.handles(Capability.NUMERIC_ATTRIBUTES))
      result.enable(Capability.NOMINAL_ATTRIBUTES);
    result.enable(Capability.MISSING_VALUES);
   
    return result;
  }
View Full Code Here

Examples of weka.core.Capabilities.handles()

   *           class
   */
  public void setClassifier(Classifier newClassifier) {
    Capabilities cap = newClassifier.getCapabilities();
   
    if (!cap.handles(Capability.NUMERIC_CLASS))
      throw new IllegalArgumentException("Base classifier cannot handle numeric class!");
     
    super.setClassifier(newClassifier);
  }

View Full Code Here

Examples of weka.core.Capabilities.handles()

    boolean  numeric;
    boolean  nominal;
   
    Capabilities cap = newClassifier.getCapabilities();

    numeric =    cap.handles(Capability.NUMERIC_CLASS)
            || cap.hasDependency(Capability.NUMERIC_CLASS);
   
    nominal =    cap.handles(Capability.NOMINAL_CLASS)
              || cap.hasDependency(Capability.NOMINAL_CLASS)
              || cap.handles(Capability.BINARY_CLASS)
View Full Code Here

Examples of weka.core.Capabilities.handles()

    Capabilities cap = newClassifier.getCapabilities();

    numeric =    cap.handles(Capability.NUMERIC_CLASS)
            || cap.hasDependency(Capability.NUMERIC_CLASS);
   
    nominal =    cap.handles(Capability.NOMINAL_CLASS)
              || cap.hasDependency(Capability.NOMINAL_CLASS)
              || cap.handles(Capability.BINARY_CLASS)
              || cap.hasDependency(Capability.BINARY_CLASS)
              || cap.handles(Capability.UNARY_CLASS)
              || cap.hasDependency(Capability.UNARY_CLASS);
View Full Code Here

Examples of weka.core.Capabilities.handles()

    numeric =    cap.handles(Capability.NUMERIC_CLASS)
            || cap.hasDependency(Capability.NUMERIC_CLASS);
   
    nominal =    cap.handles(Capability.NOMINAL_CLASS)
              || cap.hasDependency(Capability.NOMINAL_CLASS)
              || cap.handles(Capability.BINARY_CLASS)
              || cap.hasDependency(Capability.BINARY_CLASS)
              || cap.handles(Capability.UNARY_CLASS)
              || cap.hasDependency(Capability.UNARY_CLASS);
   
    if ((m_Evaluation == EVALUATION_CC) && !numeric)
View Full Code Here

Examples of weka.core.Capabilities.handles()

   
    nominal =    cap.handles(Capability.NOMINAL_CLASS)
              || cap.hasDependency(Capability.NOMINAL_CLASS)
              || cap.handles(Capability.BINARY_CLASS)
              || cap.hasDependency(Capability.BINARY_CLASS)
              || cap.handles(Capability.UNARY_CLASS)
              || cap.hasDependency(Capability.UNARY_CLASS);
   
    if ((m_Evaluation == EVALUATION_CC) && !numeric)
      throw new IllegalArgumentException(
    "Classifier needs to handle numeric class for chosen type of evaluation!");
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.