DGtal 1.4.0
|
Aim: implements a 'WT (Write-through)' write policy cache. More...
#include <DGtal/images/ImageCachePolicies.h>
Public Types | |
typedef TImageFactory | ImageFactory |
typedef TImageContainer | ImageContainer |
typedef TImageContainer::Domain | Domain |
typedef TImageContainer::Point | Point |
typedef TImageContainer::Value | Value |
Public Member Functions | |
BOOST_CONCEPT_ASSERT ((concepts::CImage< TImageContainer >)) | |
Checking concepts. | |
BOOST_CONCEPT_ASSERT ((concepts::CImageFactory< TImageFactory >)) | |
ImageCacheWritePolicyWT (Alias< ImageFactory > anImageFactory) | |
~ImageCacheWritePolicyWT () | |
void | writeInPage (ImageContainer *anImageContainer, const Point &aPoint, const Value &aValue) |
void | flushPage (ImageContainer *anImageContainer) |
Protected Attributes | |
ImageFactory * | myImageFactory |
Alias on the image factory. | |
Private Member Functions | |
ImageCacheWritePolicyWT (const ImageCacheWritePolicyWT &other) | |
ImageCacheWritePolicyWT & | operator= (const ImageCacheWritePolicyWT &other) |
Aim: implements a 'WT (Write-through)' write policy cache.
Description of template class 'ImageCacheWritePolicyWT'
Write is done synchronously both to the cache and to the disk.
TImageContainer | an image container type (model of CImage). |
TImageFactory | an image factory. |
The policy is done with 2 functions:
Definition at line 286 of file ImageCachePolicies.h.
typedef TImageContainer::Domain DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::Domain |
Definition at line 297 of file ImageCachePolicies.h.
typedef TImageContainer DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::ImageContainer |
Definition at line 296 of file ImageCachePolicies.h.
typedef TImageFactory DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::ImageFactory |
Definition at line 294 of file ImageCachePolicies.h.
typedef TImageContainer::Point DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::Point |
Definition at line 298 of file ImageCachePolicies.h.
typedef TImageContainer::Value DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::Value |
Definition at line 299 of file ImageCachePolicies.h.
|
inline |
Definition at line 301 of file ImageCachePolicies.h.
|
inline |
|
private |
DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::BOOST_CONCEPT_ASSERT | ( | (concepts::CImage< TImageContainer >) | ) |
Checking concepts.
DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::BOOST_CONCEPT_ASSERT | ( | (concepts::CImageFactory< TImageFactory >) | ) |
void DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::flushPage | ( | ImageContainer * | anImageContainer | ) |
Flush the image on disk according to the cache policy.
anImageContainer | the image. |
|
private |
void DGtal::ImageCacheWritePolicyWT< TImageContainer, TImageFactory >::writeInPage | ( | ImageContainer * | anImageContainer, |
const Point & | aPoint, | ||
const Value & | aValue ) |
Set a value on an image at a given position given by aPoint.
anImageContainer | the image. |
aPoint | the point. |
aValue | the value. |
|
protected |
Alias on the image factory.
Definition at line 340 of file ImageCachePolicies.h.