Contentserv PHP API

CSMemoryDatabaseItem
in package

Defines the item class for the memory database interface.

The class creates an item API object to receive / store key & value pair in the memory database.

Tags
since

CS23.5

Table of Contents

__construct()  : mixed
Defines the constructor of the memory database item with the required key.
getKey()  : string
Returns the defined key of the memory database item.
getLifetime()  : int
Returns the lifetime in seconds of the memory database item.
getTags()  : array<string|int, mixed>
Returns the related tags of the memory database item.
getValue()  : mixed
Returns the value of the memory database item.
setLifetime()  : void
Sets the lifetime of the memory database item.
setTags()  : void
Sets the related tag names to the memory database item.
setValue()  : void
Sets the value to the memory database item.

Methods

__construct()

Defines the constructor of the memory database item with the required key.

public final __construct(string $sKey) : mixed
Parameters
$sKey : string

The target key of the memory database item.

Tags
Return values
mixed

getKey()

Returns the defined key of the memory database item.

public getKey() : string
Tags
Return values
string

getLifetime()

Returns the lifetime in seconds of the memory database item.

public getLifetime() : int
Tags
Return values
int

getTags()

Returns the related tags of the memory database item.

public getTags() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed>

getValue()

Returns the value of the memory database item.

public getValue() : mixed
Tags
Return values
mixed

setLifetime()

Sets the lifetime of the memory database item.

public setLifetime(int $iLifetime) : void
Parameters
$iLifetime : int

The lifetime in seconds.

Tags
Return values
void

setTags()

Sets the related tag names to the memory database item.

public setTags(array<string|int, mixed> $aTags) : void
Parameters
$aTags : array<string|int, mixed>

An array of tag names, which should be set to the memory database item.

Tags
Return values
void

setValue()

Sets the value to the memory database item.

public setValue(mixed $mValue) : void
Parameters
$mValue : mixed

The value, which should be stored in the memory database item.

Tags
Return values
void

        

Search results