interface BlockServiceInterface in Opigno dashboard 3.x
Same name and namespace in other branches
- 8 src/BlockServiceInterface.php \Drupal\opigno_dashboard\BlockServiceInterface
The Opigno dashboard block service definition.
Hierarchy
- interface \Drupal\opigno_dashboard\BlockServiceInterface
Expanded class hierarchy of BlockServiceInterface
All classes that implement BlockServiceInterface
2 files declare their use of BlockServiceInterface
- DashboardController.php in src/
Controller/ DashboardController.php - SettingsForm.php in src/
Form/ SettingsForm.php
File
- src/
BlockServiceInterface.php, line 8
Namespace
Drupal\opigno_dashboardView source
interface BlockServiceInterface {
/**
* Returns all blocks.
*
* @return array
* The list of all block definitions.
*/
public function getAllBlocks() : array;
/**
* Returns available blocks.
*
* @return array
* The list of available blocks.
*/
public function getAvailableBlocks() : array;
/**
* Returns blocks contents.
*
* @return array
* The list of dashboard blocks to be rendered.
*/
public function getDashboardBlocksContents() : array;
/**
* Creates blocks instances.
*/
public function createBlocksInstances() : void;
/**
* Sanitizes ID string.
*
* @param string $id
* The block ID to be sanitized.
*
* @return string
* The sanitized block ID.
*/
public function sanitizeId(string $id) : string;
/**
* Sanitizes ID string for legacy blocks.
*
* @param string $id
* The block ID to be sanitized.
*
* @return string
* The sanitized block ID.
*/
public function sanitizeIdOld(string $id) : string;
/**
* Check if social features enabled on site or not.
*
* @return bool
* Whether social features enabled on site or not.
*/
public function isSocialFeatureEnabled() : bool;
/**
* Get the default dashboard configuration.
*
* @return string
* The default dashboard configuration.
*/
public function getDefaultDashboardConfig() : string;
/**
* The ID of default dashboard layout.
*
* @return int
* The ID of default dashboard layout.
*/
public function getDefaultLayoutId() : int;
/**
* Returns positioning.
*
* @param int|string|null $uid
* The user ID to get the positioning for.
* @param bool $default
* Should the default positioning be used or not.
* @param bool $user_default
* Should the user default positioning be used or not.
*
* @return array|\Symfony\Component\HttpFoundation\JsonResponse
* Blocks positioning.
*/
public function getPositioning($uid = NULL, bool $default = FALSE, bool $user_default = FALSE);
}
Members
Name![]() |
Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BlockServiceInterface:: |
public | function | Creates blocks instances. | 1 |
BlockServiceInterface:: |
public | function | Returns all blocks. | 1 |
BlockServiceInterface:: |
public | function | Returns available blocks. | 1 |
BlockServiceInterface:: |
public | function | Returns blocks contents. | 1 |
BlockServiceInterface:: |
public | function | Get the default dashboard configuration. | 1 |
BlockServiceInterface:: |
public | function | The ID of default dashboard layout. | 1 |
BlockServiceInterface:: |
public | function | Returns positioning. | 1 |
BlockServiceInterface:: |
public | function | Check if social features enabled on site or not. | 1 |
BlockServiceInterface:: |
public | function | Sanitizes ID string. | 1 |
BlockServiceInterface:: |
public | function | Sanitizes ID string for legacy blocks. | 1 |