Factory Methods for GEDStrategy Objects

Description

Factory Methods for GEDStrategy Objects

Usage

GEDStrategy(object, ...)

S4 (GEDStrategy)
`GEDStrategy`(object, key, ...)

S4 (function)
`GEDStrategy`(object, ..., name = NULL)

Arguments

object
object from which of a GEDalgorithm is created
...
extra arguments to allow extension
key
if not missing, it must be a character string, which is used as unique key for the new GED algorithm object. In particular, it cannot be a key already used by one of the registered algorithms, except if object and key are the only arguments and if the key matches the key of object itself, which simply returns the object unchanged -- and is somehow not a very useful call. If missing, a unique key is generated using a digest hash of the result from tempfile().
name
descriptive name of the algorithm. A temporary name is generated if missing.

Methods

  1. GEDStrategysignature(object = "missing"): This method serves as a standard constructor and is equivalent to new('GEDalgorithm', ...), meaning that all arguments must be named and correspond to slots in GEDStrategy-class.

  2. GEDStrategysignature(object = "GEDalgorithm_entry"): Method to create a GEDalgorithm object from its entry in the internal registry.

  3. GEDStrategysignature(object = "GEDStrategy"): Constructor-Copy method, which creates an GEDalgorithm object from a template and ensure that the object has a key that does not conflict with registered algorithms.

  4. GEDStrategysignature(object = "character"): This method creates a GEDalgorithm object from an access key, which allows to make objects using any registered algorithm as a template.

    The access key must be valid, i.e. that it must correspond exactly to a registered algorithm. If other arguments are passed, these must correspond to slots in GEDStrategy-class, and will overwrite the values defined by the registered algorithm.

  5. GEDStrategysignature(object = "function"): This method creates a GEDalgorithm object from a plain R function.