Original Symbian headers
Selected EUSER, Window Server, networking, graphics and device declarations
Loading...
Searching...
No Matches
RLibrary Class Reference

A handle to a dynamically loadable DLL. More...

#include <e32std.h>

Inheritance diagram for RLibrary:
RHandleBase

Classes

struct  SInfo
 
struct  TInfo
 
struct  TInfoV2
 

Public Types

enum  TRequiredImageHeaderSize { KRequiredImageHeaderSize = 9*1024 }
 
typedef TPckgBuf< TInfo > TInfoBuf
 
typedef TPckgBuf< TInfoV2 > TInfoBufV2
 
typedef TPckgBuf< SInfo > SInfoBuf
 
- Public Types inherited from RHandleBase
enum  TAttributes { EReadAccess =0x1 , EWriteAccess =0x2 , EDirectReadAccess =0x4 , EDirectWriteAccess =0x8 }
 Read/Write attributes for the handle. More...
 

Public Member Functions

IMPORT_C void Close ()
 Closes the DLL.
 
IMPORT_C TInt Load (const TDesC &aFileName, const TUidType &aType)
 Loads the named DLL which matches the specified UID type.
 
IMPORT_C TInt Load (const TDesC &aFileName, const TDesC &aPath=KNullDesC)
 Loads the named DLL.
 
IMPORT_C TInt Load (const TDesC &aFileName, const TDesC &aPath, const TUidType &aType)
 Loads the named DLL that matches the specified UID type.
 
IMPORT_C TInt Load (const TDesC &aFileName, const TDesC &aPath, const TUidType &aType, TUint32 aModuleVersion)
 Loads the named DLL that matches the specified UID type and version.
 
IMPORT_C TInt LoadRomLibrary (const TDesC &aFileName, const TDesC &aPath)
 
IMPORT_C TLibraryFunction Lookup (TInt anOrdinal) const
 Gets a pointer to the function at the specified ordinal within this DLL.
 
IMPORT_C TUidType Type () const
 Gets this DLL's UID type.
 
IMPORT_C TFileName FileName () const
 Gets the name of the DLL's file.
 
IMPORT_C TInt GetRamSizes (TInt &aCodeSize, TInt &aConstDataSize)
 Gets the current size of the code and the const data for this DLL.
 
IMPORT_C TInt Init ()
 Internal technology API.
 
- Public Member Functions inherited from RHandleBase
 RHandleBase ()
 Default constructor.
 
TInt Handle () const
 Retrieves the handle-number of the object associated with this handle.
 
void SetHandle (TInt aHandle)
 Sets the handle-number of this handle to the specified value.
 
TInt SetReturnedHandle (TInt aHandleOrError)
 Sets the handle-number of this handle to the specified value.
 
IMPORT_C void Close ()
 Closes the handle.
 
IMPORT_C TName Name () const
 Gets the name of the handle.
 
IMPORT_C TFullName FullName () const
 Gets the full name of the handle.
 
IMPORT_C void FullName (TDes &aName) const
 Gets the full name of the handle.
 
IMPORT_C void SetHandleNC (TInt aHandle)
 Sets the handle-number of this handle to the specified value, and marks it as not closable.
 
IMPORT_C TInt Duplicate (const RThread &aSrc, TOwnerType aType=EOwnerProcess)
 Creates a valid handle to the kernel object for which the specified thread already has a handle.
 
IMPORT_C void HandleInfo (THandleInfo *anInfo)
 Gets information about the handle.
 
IMPORT_C TUint Attributes () const
 
IMPORT_C TInt BTraceId () const
 Returns a unique object identifier for use with BTrace.
 
IMPORT_C void NotifyDestruction (TRequestStatus &aStatus)
 Internal technology API.
 

Static Public Member Functions

static IMPORT_C TInt GetInfoFromHeader (const TDesC8 &aHeader, TDes8 &aInfoBuf)
 Gets information about an executable binary, (DLL or EXE), based on header data from that binaries image.
 
static IMPORT_C TInt GetInfo (const TDesC &aFileName, TDes8 &aInfoBuf)
 Gets information about the specified DLL.
 
- Static Public Member Functions inherited from RHandleBase
static void DoExtendedClose ()
 

Additional Inherited Members

- Protected Member Functions inherited from RHandleBase
 RHandleBase (TInt aHandle)
 Copy constructor.
 
IMPORT_C TInt Open (const TFindHandleBase &aHandle, TOwnerType aType)
 Opens a handle to a kernel side object found using a find-handle object.
 
TInt OpenByName (const TDesC &aName, TOwnerType aOwnerType, TInt aObjectType)
 Implementation for RXxxxx::Open/OpenGlocbal(const TDesC &aName,,TOwnerType aType) functions.
 
- Static Protected Member Functions inherited from RHandleBase
static TInt SetReturnedHandle (TInt aHandleOrError, RHandleBase &aHandle)
 
- Protected Attributes inherited from RHandleBase
TInt iHandle
 

Detailed Description

A handle to a dynamically loadable DLL.

The class is not intended for user derivation.

API status
Published to all clients. Released API.

Definition at line 3334 of file e32std.h.

Member Typedef Documentation

◆ SInfoBuf

@deprecated Use TInfoBuf
API status
Internal technology API.

Definition at line 3434 of file e32std.h.

◆ TInfoBuf

Type representing a TInfo struct packaged as a descriptor.
API status
Internal technology API.

Definition at line 3386 of file e32std.h.

◆ TInfoBufV2

Type representing a TInfo struct packaged as a descriptor, version 2.
API status
Internal technology API.

Definition at line 3394 of file e32std.h.

Member Enumeration Documentation

◆ TRequiredImageHeaderSize

API status
Internal technology API.
Enumerator
KRequiredImageHeaderSize 

Definition at line 3401 of file e32std.h.

Member Function Documentation

◆ Close()

IMPORT_C void RLibrary::Close ( )

Closes the DLL.

The function decrements the usage count by one.

This handle must have been used to load the DLL using one of the Load() functions.

(generated from Symbian Developer Library)

◆ FileName()

IMPORT_C TFileName RLibrary::FileName ( ) const

Gets the name of the DLL's file.

(generated from Symbian Developer Library)

◆ GetInfo()

static IMPORT_C TInt RLibrary::GetInfo ( const TDesC &  aFileName,
TDes8 &  aInfoBuf 
)
static

Gets information about the specified DLL.

API status
Internal technology API.
Parameters
aFileNameA descriptor containing the name of the DLL to be checked. The length of the file name must not be greater than KMaxFileName.
aInfoBufOn return, contains information about the DLL (RLibrary::TInfo)

(generated from Symbian Developer Library)

◆ GetInfoFromHeader()

static IMPORT_C TInt RLibrary::GetInfoFromHeader ( const TDesC8 &  aHeader,
TDes8 &  aInfoBuf 
)
static

Gets information about an executable binary, (DLL or EXE), based on header data from that binaries image.

Parameters
aHeaderA descriptor containing the data from the start of the binaries image. This data should be of size RLibrary::KRequiredImageHeaderSize or the total length of the binary image, whichever is smallest.
aInfoBufA descriptor which will be filled with the extracted information. This information will be in the form of a RLibrary::TInfo structure. This should usually be an object of type RLibrary::TInfoBuf.

(generated from Symbian Developer Library)

◆ GetRamSizes()

IMPORT_C TInt RLibrary::GetRamSizes ( TInt &  aCodeSize,
TInt &  aConstDataSize 
)

Gets the current size of the code and the const data for this DLL.

This function can be called on a RAM loaded DLL or a ROM based DLL.

Parameters
aCodeSizeThe current size of the code for a RAM loaded DLL. This is zero for a ROM based DLL.
aConstDataSizeThe current size of the const data for a RAM loaded DLL. This is zero for a ROM based DLL.

(generated from Symbian Developer Library)

◆ Init()

IMPORT_C TInt RLibrary::Init ( )

Internal technology API.

◆ Load() [1/4]

IMPORT_C TInt RLibrary::Load ( const TDesC &  aFileName,
const TDesC &  aPath,
const TUidType &  aType 
)

Loads the named DLL that matches the specified UID type.

If successful, the function increments the usage count by one.

Parameters
aFileNameA descriptor containing the name of the DLL to be loaded. The length of the file name must not be greater than KMaxFileName.
aPathA descriptor containing a list of path names, each separated by a semicolon. When specified, these paths are searched for the DLL before the standard search locations.
aTypeA UID type (a triplet of UIDs) that the DLL must match. Individual UIDs can contain the KNullUid wild card.

(generated from Symbian Developer Library)

◆ Load() [2/4]

IMPORT_C TInt RLibrary::Load ( const TDesC &  aFileName,
const TDesC &  aPath,
const TUidType &  aType,
TUint32  aModuleVersion 
)

Loads the named DLL that matches the specified UID type and version.

If successful, the function increments the usage count by one.

Parameters
aFileNameA descriptor containing the name of the DLL to be loaded. The length of the file name must not be greater than KMaxFileName.
aPathA descriptor containing a list of path names, each separated by a semicolon. When specified, these paths are searched for the DLL before the standard search locations.
aTypeA UID type (a triplet of UIDs) that the DLL must match. Individual UIDs can contain the KNullUid wild card.
aModuleVersionA version specification that the DLL must match. Major version must match exactly and minor version must be >= the specified minor version.

(generated from Symbian Developer Library)

◆ Load() [3/4]

IMPORT_C TInt RLibrary::Load ( const TDesC &  aFileName,
const TDesC &  aPath = KNullDesC 
)

Loads the named DLL.

If successful, the function increments the usage count by one.

Parameters
aFileNameA descriptor containing the name of the DLL to be loaded. The length of the file name must not be greater than KMaxFileName.
aPathA descriptor containing a list of path names, each separated by a semicolon. When specified, these paths are searched for the DLL before the standard search locations. By default, no pathnames are specified.

(generated from Symbian Developer Library)

◆ Load() [4/4]

IMPORT_C TInt RLibrary::Load ( const TDesC &  aFileName,
const TUidType &  aType 
)

Loads the named DLL which matches the specified UID type.

If successful, the function increments the usage count by one. No additional search paths can be specified with this function.

Parameters
aFileNameA descriptor containing the name of the DLL to be loaded. The length of the file name must not be greater than KMaxFileName.
aTypeA UID type (a triplet of UIDs) which the DLL must match. Individual UIDs can contain the KNullUid wild card.

(generated from Symbian Developer Library)

◆ LoadRomLibrary()

IMPORT_C TInt RLibrary::LoadRomLibrary ( const TDesC &  aFileName,
const TDesC &  aPath 
)

◆ Lookup()

IMPORT_C TLibraryFunction RLibrary::Lookup ( TInt  anOrdinal) const

Gets a pointer to the function at the specified ordinal within this DLL.

Parameters
anOrdinalThe ordinal of the required function in this DLL. This value must be positive.

Panic condition: USER 116 if anOrdinal is negative

(generated from Symbian Developer Library)

◆ Type()

IMPORT_C TUidType RLibrary::Type ( ) const

Gets this DLL's UID type.

The UID type is a property of a Symbian OS file; for a DLL, its value is set during the building of that DLL.

(generated from Symbian Developer Library)


The documentation for this class was generated from the following files: