src/Parser.php
/**
     * Process the TaggedValue object.
     *
     * Fire any events necessary to handle the TaggedVale object which may
     * result in a modified or replacement value.
     *
     * @param  TaggedValue $value [description]
     *
     * @return mixed the value after processing. This may or may not be a
     * TaggedValue instance.
     */
Process the TaggedValue object.
Fire any events necessary to handle the TaggedVale object which may
result in a modified or replacement value.

@param  TaggedValue $value [description]

@return mixed the value after processing. This may or may not be a
TaggedValue instance.
Process the TaggedValue object . Fire any events necessary to handle the TaggedVale object which may result in a modified or replacement value . @param TaggedValue $value [ description ] @return mixed the value after processing . This may or may not be a TaggedValue instance .
protected function processTaggedValue(TaggedValue $value)
    {
        $tag = $value->getTag();
        $unprocessedEventName = join('-', [TaggedValue::class, $tag]);
        if ($this->hasEventHandlers($unprocessedEventName)) {
            $event = Yii::createObject([
                'class' => ValueEvent::class,
                'value' => $value,
            ]);
            $this->trigger($unprocessedEventName, $event);
            if ($event->handled) {
                $value = $event->getRawValue();
            }
        }
        if ($value instanceof TaggedValue) {
            $value = $value->getvalue();
        }
        $value = $this->postProcess($value);
        $value = new TaggedValue($tag, $value);
        if ($this->hasEventHandlers($tag)) {
            $event = Yii::createObject([
                'class' => ValueEvent::class,
                'value' => $value,
            ]);
            $this->trigger($tag, $event);
            if ($event->handled) {
                $value = $event->getRawValue();
            }
        }
        return $value;
    }
protected function processTaggedValue ( TaggedValue $ value ) { $ tag = $ value -> getTag ( ) ; $ unprocessedEventName = join ( '-' , [ TaggedValue :: class , $ tag ] ) ; if ( $ this -> hasEventHandlers ( $ unprocessedEventName ) ) { $ event = Yii :: createObject ( [ 'class' => ValueEvent :: class , 'value' => $ value , ] ) ; $ this -> trigger ( $ unprocessedEventName , $ event ) ; if ( $ event -> handled ) { $ value = $ event -> getRawValue ( ) ; } } if ( $ value instanceof TaggedValue ) { $ value = $ value -> getvalue ( ) ; } $ value = $ this -> postProcess ( $ value ) ; $ value = new TaggedValue ( $ tag , $ value ) ; if ( $ this -> hasEventHandlers ( $ tag ) ) { $ event = Yii :: createObject ( [ 'class' => ValueEvent :: class , 'value' => $ value , ] ) ; $ this -> trigger ( $ tag , $ event ) ; if ( $ event -> handled ) { $ value = $ event -> getRawValue ( ) ; } } return $ value ; }
Process the TaggedValue object.
Process the TaggedValue object .
// process by any raw TaggedValue event handlers // send an event with the unprocessed inner value // unwrap the inner value from inside the TaggedValue instance // process the inner value // wrap it back up into a new TaggedValue instance // process by any tag event handlers // send an event with the processed inner value