Package pl.mkaczara.bch.decoder

Source Code of pl.mkaczara.bch.decoder.BCHDecoderWorkerFactory

package pl.mkaczara.bch.decoder;

import pl.mkaczara.bch.code.CyclicCode;
import pl.mkaczara.bch.decoder.worker.AbstractBCHDecoderWorker;
import pl.mkaczara.bch.decoder.worker.DedicatedBCHDecoderWorker;
import pl.mkaczara.bch.decoder.worker.SimpleBCHDecoderWorker;

/**
* Klasa reprezentujaca obiekty fabryki dekoderow kodu BCH
*
* @author MichaƂ
*/
public final class BCHDecoderWorkerFactory {
   
    /**
     * Pobiera dekoder dla kodu i trybu
     *
     * @param code kod
     * @param simpleDecoder flaga trybu
     * @return dekoder
     */
    public static AbstractBCHDecoderWorker getBCHDecoderWorker(CyclicCode code, boolean simpleDecoder) {
        //Dekoder prosty
        if(simpleDecoder){
            return new SimpleBCHDecoderWorker(code);
        }
      
        return new DedicatedBCHDecoderWorker(code);
    }
} // end BCHEncoderWorkerFactory
TOP

Related Classes of pl.mkaczara.bch.decoder.BCHDecoderWorkerFactory

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.