Example #1
0
        public static AlgorithmInfo ToInfo(this IAlgorithm alg)
        {
            CompositeAlgorithm composite = alg as CompositeAlgorithm;

            if (composite != null)
            {
                return(composite.ToInfo());
            }

            AlgorithmBase algBase = alg as AlgorithmBase;

            if (algBase == null)
            {
                throw new Exception("Failed to derive Base implementation for IAlgorithm");
            }
            return(algBase.ToInfo());
        }
Example #2
0
 public static IEnumerable <Type> GetKnownTypes()
 {
     return(AlgorithmBase.GetKnownTypes());
 }