src/Charcoal/Admin/Ui/StructureContainerTrait.php
public function setDisplay($display)
    {
        if ($display === null) {
            $this->display = null;

            return $this;
        }

        if (!is_string($display)) {
            throw new InvalidArgumentException(sprintf(
                'Layout must be a string, received %s',
                (is_object($display) ? get_class($display) : gettype($display))
            ));
        }

        $supportedLayouts = $this->supportedDisplayLayouts();
        if (!in_array($display, $supportedLayouts)) {
            throw new OutOfBoundsException(sprintf(
                'Unsupported layout [%s]; must be one of %s',
                $display,
                implode(', ', $supportedLayouts)
            ));
        }

        $this->display = $display;

        return $this;
    }
public function setDisplay($display)
    {
        if ($display === null) {
            $this->display = null;

            return $this;
        }

        if (!is_string($display)) {
            throw new InvalidArgumentException(sprintf(
                'Layout must be a string, received %s',
                (is_object($display) ? get_class($display) : gettype($display))
            ));
        }

        $supportedLayouts = $this->supportedDisplayLayouts();
        if (!in_array($display, $supportedLayouts)) {
            throw new OutOfBoundsException(sprintf(
                'Unsupported layout [%s]; must be one of %s',
                $display,
                implode(', ', $supportedLayouts)
            ));
        }

        $this->display = $display;

        return $this;
    }
public function setDisplay ( $ display ) { if ( $ display === null ) { $ this -> display = null ; return $ this ; } if ( ! is_string ( $ display ) ) { throw new InvalidArgumentException ( sprintf ( 'Layout must be a string, received %s' , ( is_object ( $ display ) ? get_class ( $ display ) : gettype ( $ display ) ) ) ) ; } $ supportedLayouts = $ this -> supportedDisplayLayouts ( ) ; if ( ! in_array ( $ display , $ supportedLayouts ) ) { throw new OutOfBoundsException ( sprintf ( 'Unsupported layout [%s]; must be one of %s' , $ display , implode ( ', ' , $ supportedLayouts ) ) ) ; } $ this -> display = $ display ; return $ this ; }
Set the property's display layout.

@param  string $display The layout for the tickable elements.
@throws InvalidArgumentException If the given layout is invalid.
@throws OutOfBoundsException If the given layout is unsupported.
@return self
Set the property s display layout .