Contentserv PHP API

CSMemoryDatabaseMemcacheService extends _CSMemoryDatabaseService
in package

Defines the abstract class for the memory database services.

The class provides the base object with getter method to receive information for a specific service type.

Tags

Table of Contents

__construct()  : mixed
Defines the constructor of the memory database service.
deleteItem()  : bool
Deletes a memory database item for a given key.
getConfiguration()  : CSMemoryDatabaseConfiguration
Returns the given & stored configuration of the memory database service.
getItem()  : CSMemoryDatabaseItem
Returns the memory database item for the given key.
getMode()  : int
Returns the current mode of the service.
getResponseTime()  : float|null
Receives the current response time in micro seconds of the service.
getSessionHandler()  : CSMemoryDatabaseSessionHandler|null
Returns a session handler API object if the service provides a separate session handling.
getVersion()  : string
Receives version information from the service.
invalidate()  : bool
Invalidate memory database items for specific given tag names.
isConnected()  : bool
Checks if the service is connected.
isEnabled()  : bool
Checks if the service is enabled.
isMode()  : bool
Checks if the given mode is active in the memory database service.
prepareErrorMessage()  : void
Provides the possibility to modify / prepare error message specific for a service type.
setItem()  : bool
Sets & stores a given memory database item to the service storage.

Methods

deleteItem()

Deletes a memory database item for a given key.

public deleteItem(string $sKey) : bool
Parameters
$sKey : string

The target key of the item.

Tags
inheritDoc
Return values
bool

getResponseTime()

Receives the current response time in micro seconds of the service.

public getResponseTime() : float|null
Tags
inheritDoc
Return values
float|null

invalidate()

Invalidate memory database items for specific given tag names.

public invalidate([array<string|int, mixed> $aTags = [] ]) : bool
Parameters
$aTags : array<string|int, mixed> = []

An array with tag names that should be deleted.

Tags
inheritDoc
Return values
bool

isMode()

Checks if the given mode is active in the memory database service.

public final isMode(int $iMode) : bool
Parameters
$iMode : int

The mode, which should be checked. Please use the constants "CSMemoryDatabaseConst::MODE_"

Tags
Return values
bool

prepareErrorMessage()

Provides the possibility to modify / prepare error message specific for a service type.

public prepareErrorMessage(string &$sMessage, int $iErrorType, bool &$bShowTrace) : void
Parameters
$sMessage : string

The original error message.

$iErrorType : int

The error type.

$bShowTrace : bool

Whether the trace should be shown for the corresponding error message.

Tags
inheritDoc
Return values
void

        

Search results