Esempio n. 1
0
 public BucketTransform(BucketTransform oriTrans)
 {
     this.minValue = oriTrans.minValue;
     this.minInclusive = oriTrans.minInclusive;
     this.maxValue = oriTrans.maxValue;
     this.maxInclusive = oriTrans.maxInclusive;
 }
Esempio n. 2
0
        public static TransformFunction Create(string funcName, string[] parameters, int idxStart)
        {
            TransformFunction transFunc;
            switch (funcName)
            {
                case "linear":
                    transFunc = new LinearTransform(parameters, idxStart);
                    break;
                case "bucket":
                    transFunc = new BucketTransform(parameters, idxStart);
                    break;
                case "rational":
                    transFunc = new RationalTransform(parameters, idxStart);
                    break;
                case "loglinear":
                    transFunc = new LogLinearTransform(parameters, idxStart);
                    break;
                case "DecisionTree":
                    transFunc = new DecisionTreeTransform(parameters, idxStart);
                    break;
                case "BM25F2":
                    transFunc = new BM25F2Transform(parameters, idxStart);
                    break;
                case "LogBM25F2":
                    transFunc = new LogBM25F2Transform(parameters, idxStart);
                    break;
                default:
                    throw new Exception("un-handled input transformation " + funcName);
            }

            return transFunc;
        }