| 84 | |
| 85 | template<typename B, typename Q> |
| 86 | module::Decoder_SIHO<B, Q>* |
| 87 | Decoder ::build(module::Encoder<B>* encoder) const |
| 88 | { |
| 89 | if (encoder) |
| 90 | { |
| 91 | if (this->type == "ML") |
| 92 | { |
| 93 | if (this->implem == "STD") |
| 94 | return new module::Decoder_ML_std<B, Q>(this->K, this->N_cw, *encoder, this->hamming); |
| 95 | if (this->implem == "NAIVE") |
| 96 | return new module::Decoder_ML_naive<B, Q>(this->K, this->N_cw, *encoder, this->hamming); |
| 97 | } |
| 98 | else if (this->type == "CHASE") |
| 99 | { |
| 100 | if (this->implem == "STD") |
| 101 | return new module::Decoder_chase_std<B, Q>(this->K, this->N_cw, *encoder, this->flips, this->hamming); |
| 102 | } |
| 103 | } |
| 104 | |
| 105 | throw spu::tools::cannot_allocate(__FILE__, __LINE__, __func__); |
| 106 | } |
| 107 | |
| 108 | // ==================================================================================== explicit template instantiation |
| 109 | #include "Tools/types.h" |
nothing calls this directly
no outgoing calls
no test coverage detected