#include <ExpansibleRasterFactory.h>
Public Types | |
typedef FactoryDictionary < AbstractFactory< Raster, std::string, TKEYCOMPARE > , std::string, TKEYCOMPARE > | dictionary_type |
typedef AbstractFactory | factory_type |
Public Member Functions | |
std::map< std::string, std::string > | getCapabilities () const |
It returns a map<string, string> containing all supported formats. More... | |
void | getCreationalParameters (std::vector< std::pair< std::string, std::string > > ¶ms) const |
It returns the list of parameters accepted as raster info. More... | |
const std::string & | getKey () const |
It returns the factory key associated to the concreate factory. More... | |
const std::string & | getType () const |
Returns the type (name) of this factory. More... | |
~ExpansibleRasterFactory () | |
Static Public Member Functions | |
static void | finalize () |
It finalizes the factory: the singleton instance will be destroyed and will be unregistered from the abstract factory DataSourceFactory. More... | |
static const factory_type * | find (const std::string &factoryKey) |
static dictionary_type & | getDictionary () |
It returns a reference to the internal dictionary of concrete factories. More... | |
static void | initialize () |
It initializes the factory: the singleton instance will be registered in the abstract factory DataSourceFactory. More... | |
static Raster * | make () |
It creates and returns an empty raster with default raster driver. More... | |
static Raster * | make (const std::string &rType) |
It creates an empty raster with the proper driver. More... | |
static Raster * | make (Grid *g, const std::vector< BandProperty * > bands, const std::map< std::string, std::string > &rinfo, void *h=0, void(*deleter)(void *)=0) |
It creates a raster with the given parameters using the default raster driver. More... | |
static Raster * | make (const std::string &rType, Grid *g, const std::vector< BandProperty * > bands, const std::map< std::string, std::string > &rinfo, void *h=0, void(*deleter)(void *)=0) |
It creates a raster with the given parameters using a proper driver. More... | |
static Raster * | make (const std::map< std::string, std::string > &rinfo, void *h=0, void(*deleter)(void *)=0) |
It creates a raster with the given parameters using the default driver. More... | |
static Raster * | make (const std::string &rType, const std::map< std::string, std::string > &rinfo, void *h, void(*deleter)(void *)=0) |
It creates a raster with the given parameters using a proper driver. More... | |
static Raster * | open (const std::map< std::string, std::string > &rinfo, te::common::AccessPolicy p=te::common::RAccess) |
It opens a raster with the given parameters and default raster driver. More... | |
static Raster * | open (const std::string &rType, const std::map< std::string, std::string > &rinfo, te::common::AccessPolicy p=te::common::RAccess) |
It creates a raster with the given parameters. More... | |
static Raster * | open (const std::string &key, const std::string &value, te::common::AccessPolicy p=te::common::RAccess) |
It creates a raster with the given parameters and default raster driver. More... | |
static Raster * | open (const std::string &rType, const std::string &key, const std::string &value, te::common::AccessPolicy p=te::common::RAccess) |
It creates a raster with the given parameters. More... | |
Protected Member Functions | |
te::rst::Raster * | build () |
Concrete factories (derived from this one) must implement this method in order to create objects. More... | |
te::rst::Raster * | create (te::rst::Grid *g, const std::vector< te::rst::BandProperty * > bands, const std::map< std::string, std::string > &rinfo, void *h=0, void(*deleter)(void *)=0) |
This method must be implemented by subclasses (raster drivers). More... | |
ExpansibleRasterFactory () | |
virtual Raster * | iOpen (const std::map< std::string, std::string > &rinfo, te::common::AccessPolicy p=te::common::RAccess) |
This method may be re-implemented by subclasses in order to have a finner control for the raster object instantiation. More... | |
Protected Attributes | |
std::string | m_factoryKey |
The key that identifies the concrete factory: it will be used for unregistering the factory during destruction. More... | |
Static Private Attributes | |
static ExpansibleRasterFactory * | sm_factoryPointer |
is the concrete factory for expansible raster.
Definition at line 50 of file ExpansibleRasterFactory.h.
|
inherited |
Definition at line 73 of file AbstractFactory.h.
|
inherited |
Definition at line 77 of file AbstractFactory.h.
te::mem::ExpansibleRasterFactory::~ExpansibleRasterFactory | ( | ) |
Definition at line 43 of file ExpansibleRasterFactory.cpp.
|
protected |
Definition at line 58 of file ExpansibleRasterFactory.cpp.
|
protectedvirtual |
Concrete factories (derived from this one) must implement this method in order to create objects.
Implements te::common::AbstractFactory< Raster, std::string >.
Definition at line 94 of file ExpansibleRasterFactory.cpp.
|
protectedvirtual |
This method must be implemented by subclasses (raster drivers).
g | The raster grid. May be a NULL parameter. Implementations must take its ownership. |
bands | A vector of band properties, one for each band. Implementations must take ownership of the pointers in this vector. |
rinfo | The necessary information to create the raster. |
h | It may be any specific value for a given driver. May be a NULL parameter. |
deleter | A pointer to a deleter function used to free the memory pointed by h. May be a NULL parameter. Implementations must use this method when it doesn't use 'h' anymore. |
Implements te::rst::RasterFactory.
Definition at line 63 of file ExpansibleRasterFactory.cpp.
References TE_TR.
|
static |
It finalizes the factory: the singleton instance will be destroyed and will be unregistered from the abstract factory DataSourceFactory.
Definition at line 110 of file ExpansibleRasterFactory.cpp.
Referenced by te::mem::Module::finalize().
|
staticinherited |
|
virtual |
It returns a map<string, string> containing all supported formats.
Implements te::rst::RasterFactory.
Definition at line 99 of file ExpansibleRasterFactory.cpp.
|
virtual |
It returns the list of parameters accepted as raster info.
Implements te::rst::RasterFactory.
Definition at line 52 of file ExpansibleRasterFactory.cpp.
|
staticinherited |
It returns a reference to the internal dictionary of concrete factories.
The dictionary is a singleton.
|
inherited |
It returns the factory key associated to the concreate factory.
|
virtual |
Returns the type (name) of this factory.
Implements te::rst::RasterFactory.
Definition at line 47 of file ExpansibleRasterFactory.cpp.
References sg_expansibleRasterFactoryId().
|
static |
It initializes the factory: the singleton instance will be registered in the abstract factory DataSourceFactory.
Definition at line 104 of file ExpansibleRasterFactory.cpp.
Referenced by te::mem::Module::initialize().
|
protectedvirtualinherited |
This method may be re-implemented by subclasses in order to have a finner control for the raster object instantiation.
rinfo | The necessary information to open the raster. |
p | The access policy. |
Definition at line 122 of file RasterFactory.cpp.
Referenced by te::rst::RasterFactory::open().
|
staticinherited |
It creates and returns an empty raster with default raster driver.
Definition at line 35 of file RasterFactory.cpp.
References te::common::AbstractFactory< TPRODUCT, TFACTORYKEY, TKEYCOMPARE >::make(), and TE_DEFAULT_RASTER_TYPE.
Referenced by te::qt::widgets::ColorTransformWizard::buildOutputRaster(), te::sa::KernelOperation::buildRaster(), te::rp::ComposeBands(), te::tools::rastermanager::RasterManager::copyRaster(), te::rst::CreateCopy(), te::rp::Segmenter::createCutOffLinesTiff(), te::rp::SequenceMosaic::createDiskRasterCopy(), te::rp::CreateNewGdalRaster(), te::rp::CreateRasterFileFromMatrix(), te::idl::createRasterFromIdlArray(), te::rp::TiePointsLocatorStrategy::createTifFromMatrix(), te::rp::Skeleton::createTifFromVecField(), te::rst::CropRaster(), te::rp::DecomposeBands(), te::rp::PCAFusion::execute(), te::rp::GeoMosaic::execute(), te::rp::Register::execute(), te::rp::ArithmeticOperations::execute(), te::rp::Filter::execute(), te::rp::TiePointsMosaic::execute(), te::rp::WisperFusion::execute(), te::rp::Skeleton::execute(), te::rp::MixtureModel::execute(), te::rp::Classifier::execute(), te::rp::Segmenter::execute(), te::rp::Contrast::execute(), te::qt::widgets::ClippingWizard::executeLayerClipping(), te::rp::SegmenterRegionGrowingStrategy::exportSegs2Tif(), te::rp::TiePointsLocatorStrategy::features2Tiff(), te::map::GetExtentRaster(), te::rp::RasterResample(), te::rst::Reproject(), te::gdal::Raster::resample(), te::rst::Raster::resample(), te::attributefill::VectorToRaster::run(), te::rp::IHSFusion::saveIHSData(), te::gdal::Raster::transform(), and te::rst::Raster::trim().
|
staticinherited |
It creates an empty raster with the proper driver.
rType | The name of the specific driver to be used to create the raster. |
Definition at line 40 of file RasterFactory.cpp.
References te::common::Convert2UCase(), and te::common::AbstractFactory< TPRODUCT, TFACTORYKEY, TKEYCOMPARE >::make().
|
staticinherited |
It creates a raster with the given parameters using the default raster driver.
g | The raster grid. The factory will take its ownership. |
bands | A vector of band properties with one property for each band. The factory will take the ownership of all properties. |
rinfo | The necessary information to create the raster. |
h | It may be any specific value for a given driver. |
deleter | A pointer to a deleter function used to free the memory pointed by h. |
Definition at line 47 of file RasterFactory.cpp.
References te::common::Convert2UCase(), and TE_DEFAULT_RASTER_TYPE.
|
staticinherited |
It creates a raster with the given parameters using a proper driver.
rType | The name of the specific driver to create the raster. |
g | The raster grid. The factory will take its ownership. |
bands | A vector of band properties, one property for each band. The factory will take the ownership of all properties. |
rinfo | The necessary information to create the raster. |
h | It may be any specific value for a given driver. |
deleter | A pointer to a deleter function used to free the memory pointed by h. |
Definition at line 58 of file RasterFactory.cpp.
References te::common::Convert2UCase(), te::rst::RasterFactory::create(), te::common::FactoryDictionary< TFACTORY, TFACTORYKEY, TKEYCOMPARE >::find(), te::common::AbstractFactory< TPRODUCT, TFACTORYKEY, TKEYCOMPARE >::getDictionary(), and TE_TR.
|
staticinherited |
It creates a raster with the given parameters using the default driver.
rinfo | The necessary information to create the raster. |
h | It may be any specific value for a given driver. |
deleter | A pointer to a deleter function used to free the memory pointed by h. |
Definition at line 74 of file RasterFactory.cpp.
References TE_DEFAULT_RASTER_TYPE.
|
staticinherited |
It creates a raster with the given parameters using a proper driver.
rType | The name of the specific driver to create the raster. |
rinfo | The necessary information to create the raster. |
h | It may be any specific value for a given driver. |
deleter | A pointer to a deleter function used to free the memory pointed by h. |
Definition at line 79 of file RasterFactory.cpp.
|
staticinherited |
It opens a raster with the given parameters and default raster driver.
rinfo | The necessary information to open the raster. |
p | The access policy. |
Definition at line 84 of file RasterFactory.cpp.
References TE_DEFAULT_RASTER_TYPE.
Referenced by te::rp::FeederConstRasterDirectory::applyGeometryRestriction(), te::qt::widgets::MultiResolutionWidget::fromFile(), te::tools::rastermanager::Utils::getRaster(), te::map::RasterLayer::getRaster(), te::map::RasterLayer::getSchema(), te::rp::FeederConstRasterInfo::moveNext(), te::rp::FeederConstRasterDirectory::moveNext(), te::rp::FeederConstRasterInfo::moveTo(), te::rp::FeederConstRasterDirectory::moveTo(), te::mem::Raster::open(), te::rp::FeederConstRasterInfo::reset(), te::rp::FeederConstRasterDirectory::reset(), te::map::RasterLayer::setRasterInfo(), and te::gdal::Raster::transform().
|
staticinherited |
It creates a raster with the given parameters.
rType | The name of the specific driver to create the raster. |
rinfo | The necessary information to open the raster. |
p | The access policy. |
Definition at line 89 of file RasterFactory.cpp.
References te::common::Convert2UCase(), te::common::FactoryDictionary< TFACTORY, TFACTORYKEY, TKEYCOMPARE >::find(), te::common::AbstractFactory< TPRODUCT, TFACTORYKEY, TKEYCOMPARE >::getDictionary(), te::rst::RasterFactory::iOpen(), and TE_TR.
|
staticinherited |
It creates a raster with the given parameters and default raster driver.
key | The name of the key used to define raster location, ex.: "URI". |
value | The value of the key to define raster location, ex.: "/path/to/raster.tif". |
p | The access policy. |
Definition at line 103 of file RasterFactory.cpp.
References TE_DEFAULT_RASTER_TYPE.
|
staticinherited |
It creates a raster with the given parameters.
rType | The name of the specific driver to create the raster. |
key | The name of the key used to define raster location, ex.: "URI". |
value | The value of the key to define raster location, ex.: "/path/to/raster.tif". |
p | The access policy. |
Definition at line 108 of file RasterFactory.cpp.
|
protectedinherited |
The key that identifies the concrete factory: it will be used for unregistering the factory during destruction.
Definition at line 136 of file AbstractFactory.h.
|
staticprivate |
Definition at line 79 of file ExpansibleRasterFactory.h.