‪TYPO3CMS  ‪main
TYPO3\CMS\Core\Context\WorkspaceAspect Class Reference
Inheritance diagram for TYPO3\CMS\Core\Context\WorkspaceAspect:

Public Member Functions

 __construct (int $workspaceId=0)
int bool get (string $name)
 getId ()
 isLive ()

Protected Attributes

int $workspaceId

Detailed Description

The aspect contains information about the currently accessed workspace.

Allowed properties:

  • ‪id
  • ‪isLive
  • ‪isOffline

Definition at line 30 of file WorkspaceAspect.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Core\Context\WorkspaceAspect::__construct ( int  $workspaceId = 0)

Member Function Documentation

◆ get()

int bool TYPO3\CMS\Core\Context\WorkspaceAspect::get ( string  $name)

Fetch the workspace ID, or evaluated the state if it's 'online' or 'offline'


Implements TYPO3\CMS\Core\Context\AspectInterface.

Definition at line 47 of file WorkspaceAspect.php.

References TYPO3\CMS\Core\Context\WorkspaceAspect\$workspaceId, and TYPO3\CMS\Core\Context\WorkspaceAspect\isLive().

◆ getId()

TYPO3\CMS\Core\Context\WorkspaceAspect::getId ( )

Return the workspace ID

Definition at line 63 of file WorkspaceAspect.php.

References TYPO3\CMS\Core\Context\WorkspaceAspect\$workspaceId.

◆ isLive()

TYPO3\CMS\Core\Context\WorkspaceAspect::isLive ( )

Return whether this is live workspace or in a custom offline workspace

Definition at line 71 of file WorkspaceAspect.php.

Referenced by TYPO3\CMS\Core\Context\WorkspaceAspect\get().

Member Data Documentation

◆ $workspaceId

int TYPO3\CMS\Core\Context\WorkspaceAspect::$workspaceId