@param null $name

@return ElementTextTwbs
772949
static function laraform($name = null) {
        $el = new ElementDaterangepickerTwbs($name);
        $el->setWrapClass('js-daterangepicker-twbs');
        $el->putTextTwbs('from')->setAttribute('style','display:none');
        $el->putTextTwbs('to')->setAttribute('style','display:none');
        $el->putStaticTwbs('<div class="col-lg-12"><i class="fa fa-calendar"></i>&nbsp;<span></span> <b class="caret"></b></div>');
        //$el->putStaticTwbs('<i class="fa fa-calendar"></i>&nbsp;<span></span> <b class="caret"></b>');
        return $el;
    }
494639
public function textarea(String $name = NULL, String $value = NULL, Array $_attributes = [])
    {
        $this->setNameAttribute($name);

        $this->setValueAttribute($value);

        if( ! empty($this->settings['attr']['name']) )
        {
            $this->_postback($this->settings['attr']['name'], $value);

            # 5.8.2.8[added]
            $this->getVMethodMessages();

            # 5.4.2[added]
            $this->_validate($this->settings['attr']['name'], $this->settings['attr']['name']);
            
            # 5.4.2[added]|5.4.5|5.4.6[edited]
            $value = $this->_getrow('textarea', $value, $this->settings['attr']);
        }

        $this->commonMethodsForInputElements('textarea');

        $this->getPermAttribute($perm);

        $this->createTextareaElementByValueAndAttributes($value, $_attributes, $return);

        $this->createBootstrapFormInputElementByType('textarea', $return, $_attributes, $return);

        $this->outputElement .= $this->_perm($perm, $return);

        return $this;
    }
1249216
public static function generate($name = null)
	{
		$name = $name ?: self::getName();

		return '<label id="hypt_' . $name . '_wrap" style="display:none;">' . "\n" .
					'Leave this field empty:' . "\n" .
					Input::input('text', $name . '[p]') . "\n" .
					Input::input('text', $name . '[t]', self::getEncrypter()->encrypt(time())) . "\n" .
				'</label>' . "\n";
	}
69247
public function getElement(string $name): Element
    {
        if ($this->page_object_factory === null) {
            throw new RuntimeException('[W406] To create elements you need to pass a factory with setPageObjectFactory()');
        }

        return $this->page_object_factory->createElement($name);
    }
321293
public function get($name)
    {
        if ($this->has($name)) {
            return $this->elements[$name];
        }

        throw new \InvalidArgumentException(sprintf('Element "%s" does not exist.', $name));
    }
980234
public function isElementInTable(string $name): bool
    {
        return $this->context->getElementByText($name, $this->fields['listElement']) !== null;
    }
1220652
public function getElementMinOccurs($name)
    {
        foreach ($this->element->getElementsByTagName('element') as $element) {
            if ($element->getAttribute('name') == $name) {
                $minOccurs = $element->getAttribute('minOccurs');
                if ($minOccurs === '') {
                    return null;
                }
                return (int) $minOccurs;
            }
        }
        return null;
    }
877188
public static function getCharacterSetEciByName(string $name) : ?self
    {
        $nameToEci = self::nameToEci();
        $name = strtolower($name);

        if (! array_key_exists($name, $nameToEci)) {
            return null;
        }

        return $nameToEci[$name];
    }
430830
public function name($name = null)
    {
        if ($name === null) {
            return $name;
        }
        $this->_name = $name;

        return $this;
    }
81129
public function addTextarea(string $name) : Element\Textarea
    {
        $textarea = new Element\Textarea($this, $name);
        $this->addComponent($name, $textarea);

        return $textarea;
    }
1021843
static function laraform($name) {
        $el = new ElementSwitchTwbs($name);
        $el->addClass('js-bootstrap-switch')
            ->setOffClass('danger')
            ->setOffLabel('Нет')
            ->setOnClass('success')
            ->setOnLabel('Да')
            ->setSizeSmall();

        return $el;
    }
310193
public static function getTag(string $name)
    {
        if (isset(self::$tags[$name])) {
            return self::$tags[$name];
        }
        $class = '\\sdopx\\plugin\\' . Utils::toCamel($name) . 'Tag';
        if (class_exists($class)) {
            self::$tags[$name] = new $class();
            return self::$tags[$name];
        }
        return null;
    }
1199190
public function tag($name, $text = null, array $options = [])
    {
        $options = optionsParser($options)->tooltip();
        list($text, $options) = $this->addIconToText($text, $options);

        return parent::tag($name, is_null($text) ? '' : $text, $options->toArray());
    }
75111
public function text($name = null, $value = null, $attr = null)
    {
        return $this->createInput('text', $name, $value, $attr);
    }
580989
public XElement childElement(String name) {
        for (XElement e : children) {
            if (e.name.equals(name)) {
                return e;
            }
        }
        return null;
    }
891513
public function element(string $name): ElementInterface
    {
        if (! isset($this->elements[$name])) {
            throw new ElementNotFoundException(
                sprintf('The element with name <code>%s</code> does not exists', $name)
            );
        }

        return $this->elements[$name];
    }
688702
static public function widget($name=null)
	{
	    if ($name = static::findClass($name, 'widget')) {
	        $id = 'widget' . ($name ? '.' . $name : '');
	        if (!static::has($id)) {
	            static::setShared($id, function () use ($name) {
	                if ($name instanceof \Wslim\View\Widget) {
	                    return $name::instance();
	                } else {
	                    return new $name;
	                }
	            });
	        }
	        return static::get($id);
	    }
	    return null;
	}