com\setasign\SetaSite\Block

BlockInterface Interface BlockInterface

File: /SetaSite/src/Block/BlockInterface.php

Note: the last arguments of __construct must always be: [BlockParentInterface $blockParent, string $blockName, array $blockData]

Implemented in

Summary

Static Methods

getBlockPath()

abstract public static BlockInterface::getBlockPath (
void
): string

Just return DIR

getConfig()

abstract public static BlockInterface::getConfig (
void
): \com\setasign\SetaFramework\Config\Config

lookupFile()

abstract public static BlockInterface::lookupFile (
string $file
): \com\setasign\SetaFramework\FileSystem\File
Parameters
$file : string
 
Exceptions

Throws \com\setasign\SetaSite\FileSystem\InvalidPathException


Methods

getData()

abstract public BlockInterface::getData (
void
): array

Returns the block data

getFullName()

abstract public BlockInterface::getFullName (
void
): string

getModuleAdapters()

If the block has some special functionality for an external module it will return an adapter for this otherwise the array is empty.

Parameters
$module : \com\setasign\SetaSite\Module\ModuleInterface
 

getName()

abstract public BlockInterface::getName (
void
): string

getPage()

getPropertyContainer()

Get the property container of the block

getUid()

abstract public BlockInterface::getUid (
void
): ?string

render()

abstract public BlockInterface::render (
void
): string
Return Values

The rendered block

Exceptions

Throws ForceResponseException If the block forces a complete response.

Throws \com\setasign\SetaSite\HttpErrorException If the block forces a http error.

Throws \com\setasign\SetaFramework\Bootstrap\MaintenanceException

Throws BlockRenderException If something went wrong on rendering the block.