001    package jcolibri.method.reuse.classification;
002    
003    import jcolibri.method.retrieve.NNretrieval.NNConfig;
004    
005    /**
006     * This class stores the configuration for the KNN classification methods.
007     * @author Lisa Cummins
008     */
009    public class KNNClassificationConfig extends NNConfig {
010    
011            /**
012             * The type of classification method being used by this
013             * config object.
014             */
015            KNNClassificationMethod classificationMethod;
016    
017            /**
018             * Returns the classification method stored in this
019             * config object.
020             * @return the classification method stored in this
021             * config object.
022             */
023            public KNNClassificationMethod getClassificationMethod()
024            {       return classificationMethod;
025            }
026    
027            /**
028             * Sets the classification method for this
029             * config object to be classificationMethod.
030             * @param classificationMethod the classification
031             * method to be used for this config object.
032             */
033            public void setClassificationMethod(KNNClassificationMethod classificationMethod)
034            {       this.classificationMethod = classificationMethod;
035            }
036            
037            private int K = Integer.MAX_VALUE;
038            
039            /**
040             * @return Returns the k.
041             */
042            public int getK() {
043                    return K;
044            }
045    
046            /**
047             * @param k The k to set.
048             */
049            public void setK(int k) {
050                    K = k;
051            }
052    }