Overview | Package | Class | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sun.mdm.index.matching
Class MatchEngineControllerImpl

    java.lang.Object
      com.sun.mdm.index.matching.MatchEngineControllerImpl

All Implemented Interfaces:
  MatchEngineController

public class MatchEngineControllerImpl
extends java.lang.Object
implements MatchEngineController

The match engine controller provides the main entry point to the Match Engine Functional Area (MEFA) and exposes the public functionality to Standardize and Match records. The strategy and means to do so are determined by the configured pluggable components such as the standardization and match engine, the BlockPicker and PassController.

Field Summary
`(package private) static java.lang.String` | `TAG_SBR`

Constructor Summary
`MatchEngineControllerImpl()` Constructor to create Match Engine Controller

Method Summary
`java.util.ArrayList` | `findMatch(java.sql.Connection con, EOSearchCriteria crit, EOSearchOptions opts, MatchOptions matchOptions)` Attempt to find a matching object by calculating the probabilities an object matches.
`java.util.ArrayList` | `findMatch(EOSearchCriteria crit, EOSearchOptions opts, MatchOptions matchOptions)` Attempt to find a matching object by calculating the probabilities an object matches.
`(package private) BlockPicker` | `getBlockPicker()` Get an instance of the configured BlockPicker.
`(package private) Matcher` | `getMatcher()` Get the local interface instance of the Matcher session EJB.
`java.util.ArrayList` | `getMatchFieldList(SystemObject sysObj)` Access the Matcher configuration and returns a list of field names First look for it in the cache, return it if found, look it up if its not.
`(package private) PassController` | `getPassController()` Get an instance of the configured PassController.
`(package private) Standardizer` | `getStandardizer()` Get the local interface instance of the Standardardizer session EJB.
`QueryResults` | `retrieveBlock(java.sql.Connection con, QueryBuilder qBuilder, EOSearchOptions options, java.lang.String[] queryIds, SystemObject sysObj, SystemObject sysObj2, SystemObject sysObj3)` Retrieves a block matching the specified SearchOptions.
`QueryResults` | `retrieveBlock(QueryBuilder qBuilder, EOSearchOptions options, java.lang.String[] queryIds, SystemObject sysObj, SystemObject sysObj2, SystemObject sysObj3)` Retrieves a block matching the specified SearchOptions.
`SystemObject` | `standardize(SystemObject objToStandardize)` Standardize the SystemObject.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### TAG_SBR

    static final java.lang.String TAG_SBR

See Also:
  Constant Field Values

Constructor Detail

### MatchEngineControllerImpl

    public MatchEngineControllerImpl()
                              throws java.lang.Exception

  Constructor to create Match Engine Controller

  Throws:
    `QueryBuilderException` - the QueryBuilderConfiguration could not be obtained
    `java.lang.Exception`

Method Detail

### findMatch

    public java.util.ArrayList findMatch(java.sql.Connection con,
                                         EOSearchCriteria crit,
                                         EOSearchOptions opts,
                                         MatchOptions matchOptions)
                                  throws MatchingException,
                                         SystemObjectException,
                                         ObjectException,
                                         java.sql.SQLException,
                                         EPathException,
                                         java.lang.InstantiationException,
                                         java.lang.ClassNotFoundException,
                                         java.lang.IllegalAccessException,
                                         UserException

  Attempt to find a matching object by calculating the probabilities an object matches.

  Specified by:
    `findMatch` in interface `MatchEngineController`
  Parameters:
    `con` - The database connection.
    `crit` - the criteria to find the match for, contains the (already standardized) SystemObject to find match for.
    `opts` - defines what enterprise objects to match against in the database
    `matchOptions` - the options to control the matching and the results to return
  Returns:
    An ArrayList of com.sun.mdm.index.matching.ScoreElement, containing information such as EUID and weight, indicating how well the the object matches. The matchOptions can influence exactly what is returned, i.e. whether it is in sorted order and whether weights below a certain threshold are removed before returning. By default the order is from the heighest weigth (= best match) first, to the lowest last - and all results are returned.
  Throws:
    `MatchingException` - matching failed
    `SystemObjectException` - accessing the configured fields required for standardization or matching on the passed in SystemObject failed
    `ObjectException` - accessing the configured fields required for standardization or matching on the passed in objects failed
    `java.sql.SQLException` - retrieving data from the database for matching failed
    `EPathException` - a configured ePath is invalid
    `java.lang.InstantiationException` - a configured implementation class for a component could not be instantiated
    `java.lang.ClassNotFoundException` - a configured implementation class for a component could not be found
    `java.lang.IllegalAccessException` - a configured implementation class for a component refused access
    `UserException`

### findMatch

    public java.util.ArrayList findMatch(EOSearchCriteria crit,
                                         EOSearchOptions opts,
                                         MatchOptions matchOptions)
                                  throws MatchingException,
                                         SystemObjectException,
                                         ObjectException,
                                         java.sql.SQLException,
                                         EPathException,
                                         java.lang.InstantiationException,
                                         java.lang.ClassNotFoundException,
                                         java.lang.IllegalAccessException,
                                         UserException

  Attempt to find a matching object by calculating the probabilities an object matches.

  Specified by:
    `findMatch` in interface `MatchEngineController`
  Parameters:
    `crit` - the criteria to find the match for, contains the (already standardized) SystemObject to find match for.
    `opts` - defines what enterprise objects to match against in the database
    `matchOptions` - the options to control the matching and the results to return
  Returns:
    An ArrayList of com.sun.mdm.index.matching.ScoreElement, containing information such as EUID and weight, indicating how well the the object matches. The matchOptions can influence exactly what is returned, i.e. whether it is in sorted order and whether weights below a certain threshold are removed before returning. By default the order is from the heighest weigth (= best match) first, to the lowest last - and all results are returned.
  Throws:
    `MatchingException` - matching failed
    `SystemObjectException` - accessing the configured fields required for standardization or matching on the passed in SystemObject failed
    `ObjectException` - accessing the configured fields required for standardization or matching on the passed in objects failed
    `java.sql.SQLException` - retrieving data from the database for matching failed
    `EPathException` - a configured ePath is invalid
    `java.lang.InstantiationException` - a configured implementation class for a component could not be instantiated
    `java.lang.ClassNotFoundException` - a configured implementation class for a component could not be found
    `java.lang.IllegalAccessException` - a configured implementation class for a component refused access
    `UserException`

### getBlockPicker

    BlockPicker getBlockPicker()
                         throws java.lang.InstantiationException,
                                java.lang.ClassNotFoundException,
                                java.lang.IllegalAccessException

  Get an instance of the configured BlockPicker.

  Returns:
    the BlockPicker implementation instance
  Throws:
    `java.lang.InstantiationException` - the configured implementation class for a component could not be instantiated
    `java.lang.InstantiationException` - the configured implementation class for a component could not be found
    `java.lang.IllegalAccessException` - the configured implementation class for a component refused access
    `java.lang.ClassNotFoundException`

### getMatcher

    Matcher getMatcher()

  Get the local interface instance of the Matcher session EJB.

  Returns:
    the local interface instance

### getMatchFieldList

    public java.util.ArrayList getMatchFieldList(SystemObject sysObj)
                                          throws EPathException,
                                                 ConfigurationException,
                                                 java.lang.InstantiationException

  Access the Matcher configuration and returns a list of field names First look for it in the cache, return it if found, look it up if its not. Each EJB instance has its own cache, speeds up access after the list has been requested more then once. Works based on the assumption that container does not destroy stateless session beans after servicing each request.

  Parameters:
    `sysObj` - a SystemObject defining the type of the object to find the match fields for
  Returns:
    the list of match fields
  Throws:
    `EPathException` - converting the ePaths to field names failed
    `ConfigurationException` - the configuration could not be retrieved
    `java.lang.InstantiationException` - a configured implementation class could not be instantiated

### getPassController

    PassController getPassController()
                               throws java.lang.InstantiationException,
                                      java.lang.ClassNotFoundException,
                                      java.lang.IllegalAccessException

  Get an instance of the configured PassController.

  Returns:
    the PassController implementation instance
  Throws:
    `java.lang.InstantiationException` - the configured implementation class for a component could not be instantiated
    `java.lang.InstantiationException` - the configured implementation class for a component could not be found
    `java.lang.IllegalAccessException` - the configured implementation class for a component refused access
    `java.lang.ClassNotFoundException`

### getStandardizer

    Standardizer getStandardizer()

  Get the local interface instance of the Standardardizer session EJB.

  Returns:
    the local interface instance

### retrieveBlock

    public QueryResults retrieveBlock(java.sql.Connection con,
                                      QueryBuilder qBuilder,
                                      EOSearchOptions options,
                                      java.lang.String[] queryIds,
                                      SystemObject sysObj,
                                      SystemObject sysObj2,
                                      SystemObject sysObj3)
                               throws QMException,
                                      SystemObjectException,
                                      ObjectException,
                                      MatchingException

  Retrieves a block matching the specified SearchOptions. Uses dynamic generated queries

  Parameters:
    `con` - the database connection
    `sysObj` - The systemObject to retrive the block for
  Returns:
    the block of records to match against
  Throws:
    `BlockerException` - a blocker operation failed
    `java.sql.SQLException` - retrieving the block from the database failed
    `SystemObjectException` - an operation on the SystemObject failed
    `EPathException` - using the configured ePaths for matching failed
    `ObjectException` - an operation on an ObjectNode failed
    `QMException`
    `MatchingException`

### retrieveBlock

    public QueryResults retrieveBlock(QueryBuilder qBuilder,
                                      EOSearchOptions options,
                                      java.lang.String[] queryIds,
                                      SystemObject sysObj,
                                      SystemObject sysObj2,
                                      SystemObject sysObj3)
                               throws QMException,
                                      SystemObjectException,
                                      ObjectException,
                                      MatchingException

  Retrieves a block matching the specified SearchOptions. Uses dynamic generated queries

  Parameters:
    `sysObj` - The systemObject to retrive the block for
  Returns:
    the block of records to match against
  Throws:
    `BlockerException` - a blocker operation failed
    `java.sql.SQLException` - retrieving the block from the database failed
    `SystemObjectException` - an operation on the SystemObject failed
    `EPathException` - using the configured ePaths for matching failed
    `ObjectException` - an operation on an ObjectNode failed
    `QMException`
    `MatchingException`

### standardize

    public SystemObject standardize(SystemObject objToStandardize)
                             throws StandardizationException,
                                    ObjectException,
                                    java.lang.InstantiationException

  Standardize the SystemObject. Required before using the object in the findMatch function. Standardizing in this context includes phoneticization.

  Specified by:
    `standardize` in interface `MatchEngineController`
  Parameters:
    `objToStandardize` - the Object to standardize. If calling this through the local interface, Warning: this method may modify the passed in objToStandardized.
  Returns:
    the standardized and phoenticized SystemObject. If calling this through the local interface, the return value may be a reference to the same object that was passed in, modified by the function.
  Throws:
    `StandardizationException` - the SystemObject could not be standardized
    `ObjectException` - the configured fields to be standardized could not be retrieved from the SystemObject
    `java.lang.InstantiationException` - the standardizer implementation could not be created

Overview | Package | Class | Tree | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Sun Microsystems, Inc.