| 30 | */ |
| 31 | template<class TModelFactory> |
| 32 | class ModelFitProviderBase : public mitk::IModelFitProvider |
| 33 | { |
| 34 | public: |
| 35 | /** Returns an instance of the model factory that is represented by the provider.*/ |
| 36 | itk::SmartPointer<ModelFactoryBase> GenerateFactory() const override; |
| 37 | |
| 38 | /** Returns the grid of the model variable extracted from the fit info. The default implementation |
| 39 | returns a time grid extracted from the time geometry of the fitInfo->inputImage. Reimplement for |
| 40 | other models/fits to generate other variable grids. |
| 41 | \pre fitInfo is a valid instance for the model fit. |
| 42 | */ |
| 43 | ModelBase::TimeGridType GetVariableGrid(const modelFit::ModelFitInfo* fitInfo) const override; |
| 44 | |
| 45 | us::ServiceRegistration<IModelFitProvider> RegisterService(us::ModuleContext *context = us::GetModuleContext()); |
| 46 | void UnregisterService(); |
| 47 | |
| 48 | ModelFitProviderBase(); |
| 49 | ~ModelFitProviderBase() override; |
| 50 | |
| 51 | protected: |
| 52 | |
| 53 | ModelFitProviderBase(const ModelFitProviderBase &other); |
| 54 | |
| 55 | virtual us::ServiceProperties GetServiceProperties() const; |
| 56 | |
| 57 | /** |
| 58 | * \brief Set the service ranking for this file reader. |
| 59 | * |
| 60 | * Default is zero and should only be chosen differently for a reason. |
| 61 | * The ranking is used to determine which reader to use if several |
| 62 | * equivalent readers have been found. |
| 63 | * It may be used to replace a default reader from MITK in your own project. |
| 64 | * E.g. if you want to use your own reader for nrrd files instead of the default, |
| 65 | * implement it and give it a higher ranking than zero. |
| 66 | */ |
| 67 | void SetRanking(int ranking); |
| 68 | int GetRanking() const; |
| 69 | |
| 70 | private: |
| 71 | ModelFitProviderBase &operator=(const ModelFitProviderBase &other); |
| 72 | |
| 73 | class Impl; |
| 74 | std::unique_ptr< Impl > d; |
| 75 | }; |
| 76 | |
| 77 | } // namespace mitk |
| 78 |
nothing calls this directly
no test coverage detected