GridStackInterface.php in GridStack 8.2
Same filename and directory in other branches
Namespace
Drupal\gridstack\EntityFile
src/Entity/GridStackInterface.phpView source
<?php
namespace Drupal\gridstack\Entity;
/**
* Provides an interface defining GridStack entity.
*/
interface GridStackInterface extends GridStackBaseInterface {
/**
* Returns the values of gridstack settings.
*
* @param bool $merged
* The flag indicating to merge values with default ones.
*
* @return mixed
* The settings values.
*/
public function getSettings($merged = TRUE);
/**
* Sets the values of gridstack settings.
*
* @param array $values
* The setting values.
* @param bool $merged
* The flag indicating to merge values with default ones.
*
* @return $this
* The class is being called.
*/
public function setSettings(array $values, $merged = TRUE);
/**
* Returns the value of a gridstack setting.
*
* @param string $name
* The setting name.
* @param mixed $default
* The default value.
*
* @return mixed
* The option value.
*/
public function getSetting($name, $default = NULL);
/**
* Sets the value of a gridstack setting.
*
* @param string $name
* The setting name.
* @param string $value
* The setting value.
*
* @return $this
* The class is being called.
*/
public function setSetting($name, $value);
/**
* Returns options.breakpoints.[lg|xl].[column|width|grids|nested].
*
* @param string $type
* The name of specific property: column, width, grids, or nested.
*
* @return mixed|array
* Available item by the given $type parameter, else empty.
*/
public function getLastBreakpoint($type = 'grids');
/**
* Returns the current nested grids with preserved indices even if empty.
*
* Only cares for the last breakpoint, others inherit its structure.
* The reason is all breakpoints may have different DOM positionings, heights
* and widths each, but they must have the same grid structure.
*
* @param int $delta
* The current delta.
*
* @return mixed|array
* Available grids by the given $delta parameter, else empty.
*/
public function getNestedGridsByDelta($delta = 0);
/**
* Returns options.breakpoints.[xs|sm|md|lg|xl], or all, else empty.
*
* If available, data may contain: column, image_style, width, grids, nested.
*
* @param string $breakpoint
* The current breakpoint: xs, sm, md, lg, xl.
*
* @return array
* Available data by the given $breakpoint parameter, else empty.
*/
public function getBreakpoints($breakpoint = NULL);
/**
* Returns regions based on available grids.
*
* @param bool $clean
* The flag to exclude region containers.
*
* @return array
* Available regions, else empty.
*/
public function prepareRegions($clean = TRUE);
}
Interfaces
Name | Description |
---|---|
GridStackInterface | Provides an interface defining GridStack entity. |