public methods ---------------------------------------------------------
960383
public static <T> Converter<T, T> identity()
	{
		@SuppressWarnings("unchecked")
		Converter<T, T> identity = (Converter<T, T>) IDENTITY;
		
		return identity;
	}
484597
public function reset()
    {
        $this->values[self::_PUBLIC] = null;
        $this->values[self::_PRIVATE] = null;
    }
1214174
public function view()
    {
        $this->set('title', $this->title);
        $this->set('buttonText', $this->buttonText);
        $this->set('baseSearchPath', $this->baseSearchPath);
        $this->set('postTo_cID', $this->postTo_cID);

        if ((string) $this->resultsURL !== '') {
            $resultsPage = null;
            $resultsURL = $this->resultsURL;
        } else {
            $resultsPage = $this->postTo_cID ? Page::getById($this->postTo_cID) : null;
            if (is_object($resultsPage) && !$resultsPage->isError()) {
                $resultsURL = $resultsPage->getCollectionPath();
            } else {
                $resultsPage = null;
                $c = Page::getCurrentPage();
                $resultsURL = $c->getCollectionPath();
            }
        }

        $resultsURL = $this->app->make('helper/text')->encodePath($resultsURL);

        $this->set('resultTargetURL', $resultsURL);
        if ($resultsPage !== null) {
            $this->set('resultTarget', $resultsPage);
        } else {
            $this->set('resultTarget', $resultsURL);
        }

        //run query if display results elsewhere not set, or the cID of this page is set
        if ($resultsPage === null && (string) $this->resultsURL === '') {
            if ((string) $this->request->request('query') !== '' || $this->request->request('akID') || $this->request->request('month')) {
                $this->do_search();
            }
        }
    }
617827
public function initialize()
    {
        if ($this->isInitialize) {
            return ;
        }

        $this->isInitialize = true;

        $this->getEventManager()->trigger(self::EVENT_INITIALIZE, $this);
    }
1104604
public function init()
	{
		if (!isset($this->htmlOptions['id'])) {
			$this->htmlOptions['id'] = $this->getId();
		}

		$classes = array();

		$validPlacements = array(
			self::PLACEMENT_ABOVE,
			self::PLACEMENT_BELOW,
			self::PLACEMENT_LEFT,
			self::PLACEMENT_RIGHT
		);

		if (isset($this->placement) && in_array($this->placement, $validPlacements)) {
			$classes[] = 'tabs-' . $this->placement;
		}

		if (!empty($classes)) {
			$classes = implode(' ', $classes);
			if (isset($this->htmlOptions['class'])) {
				$this->htmlOptions['class'] .= ' ' . $classes;
			} else {
				$this->htmlOptions['class'] = $classes;
			}
		}
	}
527420
public function initialize()
    {
        parent::initialize();

        $this->setHtmlAttribute('data-type', 'range');
        $this->setHtmlAttribute('class', 'column-filter');

        $this->getFrom()->initialize();
        $this->getTo()->initialize();

        $this->getFrom()->removeHtmlAttribute('data-type');
        $this->getTo()->removeHtmlAttribute('data-type');
    }
328688
public function execute()
    {
        if (!$this->isEmpty()) {
            $this->table->update($this->context + $this->values, $this->where)->run();
        }

        parent::execute();
    }
1066557
public function init()
	{
		list($name,$id)=$this->resolveNameID();
		if(isset($this->htmlOptions['id']))
			$id=$this->htmlOptions['id'];
		else
			$this->htmlOptions['id']=$id;
		if(isset($this->htmlOptions['name']))
			$name=$this->htmlOptions['name'];

		$this->registerClientScript();

		if($this->hasModel())
		{
			$field=$this->textArea ? 'activeTextArea' : 'activeTextField';
			echo CHtml::$field($this->model,$this->attribute,$this->htmlOptions);
		}
		else
		{
			$field=$this->textArea ? 'textArea' : 'textField';
			echo CHtml::$field($name,$this->value,$this->htmlOptions);
		}
	}
257868
public function process()
    {
        parent::process();

        if ($this->value === null) {
            $this->path = array();
        } else {
            $this->path = $this->value;
            $this->value = end($this->path);
        }
    }
1070336
public function initialize()
    {
        $this->hasMany('id', UserPasswordChange::class, 'user_id', [
            'alias' => 'PasswordChanges',
            'foreignKey' => [
                'action' => Relation::ACTION_CASCADE,
            ],
        ]);

        $this->hasMany('id', UserPasswordReset::class, 'user_id', [
            'alias' => 'PasswordResets',
            'foreignKey' => [
                'action' => Relation::ACTION_CASCADE,
            ],
        ]);

        $this->hasMany('id', UserLoginHistory::class, 'user_id', [
            'alias' => 'LoginHistory',
            'foreignKey' => [
                'action' => Relation::ACTION_CASCADE,
            ],
        ]);

        $this->belongsTo("user_type_id", UserType::class, "id", [
            "alias" => "UserType",
            "foreignKey" => [
                "allowNulls" => true,
                "message" => "The user type specified is invalid!"
            ],
        ]);
    }
1119962
public function process()
    {
        $this->processFields();

        $this->editableFields()->each(function (Field $field) {
            $field->placeholder($field->description());
            $field->setNewValue($this->getInput($field->elementName()));

            if ($field->hasValidNewValue()) {
                $field->applyFilter($this->query);
            }
        });

        if ($this->paginatorEnabled) {
            $this->paginator();
        }
    }
1317969
public function render()
    {
        if (!$this->visible) {
            return;
        }

        parent::render();

        if ($this->isSensitive()) {
            $this->renderSensitive();
        } else {
            $this->renderInsensitive();
        }
    }
910204
public function afterSave()
    {
        /** @var \yii\db\ActiveRecord|\DevGroup\DataStructure\traits\PropertiesTrait $owner */
        $owner = $this->owner;
        $event = new HasPropertiesEvent();
        $event->model = $owner;
        HasPropertiesEvent::trigger(self::class, self::EVENT_AFTER_UPDATE, $event);
        if ($this->autoSaveProperties === true) {
            $models = [&$owner];
            PropertiesHelper::storeValues($models);
        }
        $owner->changedProperties = [];
        $owner->propertiesValuesChanged = false;

        // check for auto added property groups
        $owner->ensurePropertyGroupIds();
        $autoAddedGroups = PropertyGroup::getAutoAddedGroupsIds(
            PropertiesHelper::applicablePropertyModelId($owner)
        );

        foreach ($autoAddedGroups as $id) {
            if (!in_array($id, $owner->propertyGroupIds)) {
                /** @var PropertyGroup $propertyGroup */
                $propertyGroup = PropertyGroup::loadModel(
                    $id,
                    false,
                    true,
                    86400,
                    new ServerErrorHttpException("Property group with id $id not found"),
                    true
                );
                $owner->addPropertyGroup($propertyGroup);
            }
        }
    }
801860
public function init()
	{
		if($this->nextPageLabel===null)
			$this->nextPageLabel=Yii::t('yii','Next &gt;');
		if($this->prevPageLabel===null)
			$this->prevPageLabel=Yii::t('yii','&lt; Previous');
		if($this->firstPageLabel===null)
			$this->firstPageLabel=Yii::t('yii','&lt;&lt; First');
		if($this->lastPageLabel===null)
			$this->lastPageLabel=Yii::t('yii','Last &gt;&gt;');
		if($this->header===null)
			$this->header=Yii::t('yii','Go to page: ');

		if(!isset($this->htmlOptions['id']))
			$this->htmlOptions['id']=$this->getId();
		if(!isset($this->htmlOptions['class']))
			$this->htmlOptions['class']='yiiPager';
	}
869120
public function init() {

		parent::init();

		$this->crudPermission = CoreGlobal::PERM_USER;

		$this->modelService			= Yii::$app->factory->get( 'userService' );
		$this->addressService		= Yii::$app->factory->get( 'addressService' );
		$this->modelAddressService	= Yii::$app->factory->get( 'modelAddressService' );
		$this->metaService			= Yii::$app->factory->get( 'modelMetaService' );
	}
362130
public function process()
    {
        parent::process();

        $data = &$this->getForm()->getFormData();

        if (!isset($data[$this->id])) {
            return;
        }

        $this->value = $data[$this->id];
        $length = $this->getValueLength();

        if ($length === 0) {
            $this->value = null;
        }

        if ($this->required && $length === 0) {
            $message = $this->getValidationMessage('required');
            $this->addMessage($message);
        } elseif ($this->maxlength !== null && $length > $this->maxlength) {
            $message = $this->getValidationMessage('too-long');
            $message->primary_content = sprintf(
                $message->primary_content,
                $this->maxlength
            );

            $this->addMessage($message);
        }
    }
1008357
public function next()
    {
        parent::next();
        if ($this->_validValues) {
            $this->_values->next();
        }
        $this->_validValues = $this->_values->valid();
    }