All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cdc.applic.factorization.Cutter Maven / Gradle / Ivy

There is a newer version: 0.13.3
Show newest version
package cdc.applic.factorization;

import java.util.List;

import cdc.applic.expressions.Expression;
import cdc.applic.factorization.events.CutEvent;
import cdc.applic.factorization.handlers.CutHandler;

/**
 * Cutter is used to cut objects that have an applicability.
 * 

* Given a target applicability, each object can be: *

    *
  • included when its applicability is a non empty subset of target applicability *
  • excluded when its applicability is a non empty subset of complement of target applicability *
  • cut when its applicability intersects both target applicability and its complement. *
  • degenerated when its applicability intersects neither target applicability nor its complement. *
* * @author Damien Carbonne */ public interface Cutter { /** * Cut the applicability of a list of objects in 2 parts. *

* For each object in {@code objects}, when applicability of object: *

    *
  • is a non-empty subset of {@code targetApplicability}, invokes {@link CutHandler#processIncludeObjectApplicability(Object)}. *
  • is a non-empty subset of complement of {@code targetApplicability}, invokes {@link CutHandler#processExcludeObjectApplicability(Object)}. *
  • straddles {@code targetApplicability} and its complement, invokes {@link CutHandler#processCutObjectApplicability(Object, Expression, Expression)}. *
  • intersects neither {@code targetApplicability} nor its complement, invokes {@link CutHandler#processDegenerateObjectApplicability(Object)}. *
* * @param The object type. * @param objects The objects. * @param targetApplicability The target applicability. * @param applicabilityExtractor The applicability extractor. * @param features The features to apply. * @param handler The event handler. */ public void cut(List objects, Expression targetApplicability, ApplicabilityExtractor applicabilityExtractor, FactorizationFeatures features, CutHandler handler); public List> cut(List objects, Expression targetApplicability, ApplicabilityExtractor applicabilityExtractor, FactorizationFeatures features); }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy