SessionStorageService

This service class contains functions related to storing and reading data in the session.
All public functions are available in the Twig template renderer.

Deprecated!

since 5.0.0 will be removed in 6.0.0

Namespace

IO\Services

Properties
Type Name Description

string

$language

FrontendSessionStorageFactoryContract

$sessionStorage

Methods
public __construct($sessionStorage)

SessionStorageService constructor.

Parameters

Type

Name

Description

FrontendSessionStorageFactoryContract

$sessionStorage

public setSessionValue($name, $value)
Deprecated!

since 5.0.0 will be removed in 6.0.0

Set the value in the session

Parameters

Type

Name

Description

string

$name

Name/Key of the value

mixed

$value

The value to be stored

public getSessionValue($name):mixed
Deprecated!

since 5.0.0 will be removed in 6.0.0

Get a value from the session

Parameters

Type

Name

Description

string

$name

Name/Key of the value

public getLang():string
Deprecated!

since 5.0.0 will be removed in 6.0.0

Get the language from session

public getCustomer():Customer
Deprecated!

since 5.0.0 will be removed in 6.0.0

Gets the model for the current customer from the session