Dali 3D User Interface Engine
List of all members | Public Member Functions | Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes
Dali::Internal::ImageFactoryCache::Request Struct Reference

Request is a reference counted object to control the lifetime of elements in ImageFactory's cache. More...

#include <image-factory-cache.h>

Inheritance diagram for Dali::Internal::ImageFactoryCache::Request:
Inheritance graph
[legend]
Collaboration diagram for Dali::Internal::ImageFactoryCache::Request:
Collaboration graph
[legend]

Public Member Functions

 Request (RequestLifetimeObserver &observer, RequestId reqId, ResourceId resId, const std::string &path, const ImageAttributes *attr)
 Image request. More...
 
RequestId GetId () const
 Retrieve the unique ID of this request. More...
 
void StopLifetimeObservation ()
 Called when the RequestLifetimeObserver is being destroyed. More...
 
- Public Member Functions inherited from Dali::RefObject
void Reference ()
 Increment the object's reference count. More...
 
void Unreference ()
 Decrement the object's reference count. More...
 
int ReferenceCount ()
 Retrieve the object's reference count. More...
 

Public Attributes

ResourceId resourceId
 The Ticket ID. This can be used to acquire details of the loaded resource from ResourceClient. More...
 
const std::string url
 Path to the image resource. More...
 
ImageAttributesattributes
 ImageAttributes that were used. More...
 

Protected Member Functions

virtual ~Request ()
 
- Protected Member Functions inherited from Dali::RefObject
 RefObject ()
 Default constructor. More...
 
virtual ~RefObject ()
 RefObject is intended as a base class. More...
 
 RefObject (const RefObject &rhs)
 Copy constructor. More...
 
RefObjectoperator= (const RefObject &rhs)
 Assignment operator. More...
 

Private Member Functions

 Request ()
 not defined More...
 
 Request (const Request &rhs)
 not defined More...
 
Requestoperator= (const Request &rhs)
 not defined More...
 

Private Attributes

RequestId mId
 Request id assigned by ImageFactory. More...
 
RequestLifetimeObservermLifetimeObserver
 reference to the lifetime-observer; not owned More...
 

Detailed Description

Request is a reference counted object to control the lifetime of elements in ImageFactory's cache.

When no more Image objects reference a request, it gets removed from ImageFactory cache.

Definition at line 82 of file image-factory-cache.h.

Constructor & Destructor Documentation

Dali::Internal::ImageFactoryCache::Request::Request ( RequestLifetimeObserver observer,
RequestId  reqId,
ResourceId  resId,
const std::string &  path,
const ImageAttributes attr 
)

Image request.

These requests are stored in ImageFactory's cache.

Parameters
[in]observerThe object which observes request lifetime.
[in]reqIdA unique ID for this request.
[ib]resId A unique ticket ID.
[in]pathUrl of request.
[in]attrRequested ImageAttributes.

Definition at line 40 of file image-factory-cache.cpp.

References attributes.

Dali::Internal::ImageFactoryCache::Request::~Request ( )
protectedvirtual
Dali::Internal::ImageFactoryCache::Request::Request ( )
private

not defined

Dali::Internal::ImageFactoryCache::Request::Request ( const Request rhs)
private

not defined

Member Function Documentation

RequestId Dali::Internal::ImageFactoryCache::Request::GetId ( ) const

Retrieve the unique ID of this request.

Returns
The unique ID for this request.

Definition at line 69 of file image-factory-cache.cpp.

References mId.

Referenced by Dali::Internal::ImageFactory::GetHashForCachedRequest(), and Dali::Internal::ImageFactory::RequestDiscarded().

Here is the caller graph for this function:

Request& Dali::Internal::ImageFactoryCache::Request::operator= ( const Request rhs)
private

not defined

void Dali::Internal::ImageFactoryCache::Request::StopLifetimeObservation ( )

Called when the RequestLifetimeObserver is being destroyed.

This method should only be called during destruction of the Dali core.

Definition at line 74 of file image-factory-cache.cpp.

References mLifetimeObserver.

Member Data Documentation

ImageAttributes* Dali::Internal::ImageFactoryCache::Request::attributes
RequestId Dali::Internal::ImageFactoryCache::Request::mId
private

Request id assigned by ImageFactory.

Definition at line 121 of file image-factory-cache.h.

Referenced by GetId().

RequestLifetimeObserver* Dali::Internal::ImageFactoryCache::Request::mLifetimeObserver
private

reference to the lifetime-observer; not owned

Definition at line 122 of file image-factory-cache.h.

Referenced by StopLifetimeObservation(), and ~Request().

ResourceId Dali::Internal::ImageFactoryCache::Request::resourceId
const std::string Dali::Internal::ImageFactoryCache::Request::url

The documentation for this struct was generated from the following files:
Dali Docs Home
Read more about Dali