Write a return value to stdout.

The return value is formatted or pretty-printed, and rendered in a
visibly distinct manner (in this case, as cyan).

@see self::presentValue

@param mixed $ret
351340
public function writeReturnValue($ret)
    {
        $this->lastExecSuccess = true;

        if ($ret instanceof NoReturnValue) {
            return;
        }

        $this->context->setReturnValue($ret);
        $ret    = $this->presentValue($ret);
        $indent = \str_repeat(' ', \strlen(static::RETVAL));

        $this->output->writeln(static::RETVAL . \str_replace(PHP_EOL, PHP_EOL . $indent, $ret));
    }
88876
public function dump($return = false, $print = true, $depth = 1)
    {
        $dump = $this->data();
        $links = $this->links;

        foreach ($links as $key => $link) {
            if ($depth < 1) {
                try {
                    $related = $this->{$key};
                } catch (ServerException $e) {
                    $related = array('$error' => $e->getMessage());
                }

                if ($related instanceof Resource) {
                    $dump[$key] = $related->dump(true, false, $depth+1);
                } else {
                    $dump[$key] = $related;
                }
            }
        }
        if ($links) {
            $dump['$links'] = $this->dump_links($links);
        }

        return $print ? print_r($dump, $return) : $dump;
    }
839380
private function renderValue($printFormat, array $variables)
    {
        return str_replace(
            array_map(
                function($variable) {
                    return '{{' . $variable . '}}';
                },
                array_keys($variables)
            ),
            array_values($variables),
            $printFormat
        );
    }
1289492
public function dump($value, int $output = self::OUTPUT_ECHO): string
    {
        switch ($output) {
            case self::OUTPUT_ECHO:
                echo $this->style->wrapContainer($this->dumpValue($value, '', 0));
                break;

            case self::OUTPUT_LOG:
                if (!empty($this->logger)) {
                    $this->logger->debug($this->dump($value, self::OUTPUT_RETURN));
                }
                break;

            case self::OUTPUT_RETURN:
                return $this->style->wrapContainer($this->dumpValue($value, '', 0));
        }

        //Nothing to return
        return '';
    }
987715
protected function callScssFunction($name, $argValues, &$returnValue)
    {
        $func = $this->get(static::$namespaces['function'] . $name, false);

        if (! $func) {
            return false;
        }

        $this->pushEnv();

        $storeEnv = $this->storeEnv;
        $this->storeEnv = $this->env;

        // set the args
        if (isset($func->args)) {
            $this->applyArguments($func->args, $argValues);
        }

        // throw away lines and children
        $tmp = new OutputBlock;
        $tmp->lines    = [];
        $tmp->children = [];

        $this->env->marker = 'function';
        $this->pushCallStack($this->env->marker . " " . $name);

        $ret = $this->compileChildren($func->children, $tmp);

        $this->popCallStack();

        $this->storeEnv = $storeEnv;

        $this->popEnv();

        $returnValue = ! isset($ret) ? static::$defaultValue : $ret;

        return true;
    }
617797
protected function output ($value)
    {
        $checked = self::isChecked($value) ? 'checked' : '';
        $on      = self::ON;
        echo "<input type=\"hidden\" name=\"{$this->getVerifyFieldName()}\" value=\"{$this->getVerifyFieldValue()}\" />";
        echo "<input type=\"checkbox\" name=\"{$this->getFieldName()}\" id=\"{$this->getFieldName()}\" value=\"{$on}\" " . $checked . "/>";
    }
530697
public function run( $input )
	{
		$this->state = $this->start;
		$this->pointer = 0;
		$output = $input;
		$this->wrapTape( $output );
		while( !in_array( $this->state, $this->finals ) )
		{
			if( $_counter > 200 )
				break;
			$_counter++;
			$_current = $this->getCurrent( $output, $this->pointer );
			reset( $this->transition );
			foreach( $this->transition as $trans )
			{
				if( $trans[0] == array( $this->state, $_current ) )
				{
					$value = $trans[1];
					$state = $value[0];
					$this->state = $state;
					$write = $value[1];
					$left = substr( $output, 0, $this->pointer );
					$right = substr( $output, $this->pointer+1 );
					$output = $left.$write.$right;
					$direction = $value[2];
					if( $direction == "l" )
						$this->pointer--;
					else if( $direction == "r" )
						$this->pointer++;
					$this->extendTape( $output, $this->pointer );
					$this->wrapTape( $output );
					break;
				}
			}
			echo $this->showTape( $output );
		}
		$this->cleanTape( $output );
		return $output;
	}
670818
public function present($value, $depth = null, $options = 0)
    {
        $data = $this->cloner->cloneVar($value, !($options & self::VERBOSE) ? Caster::EXCLUDE_VERBOSE : 0);

        if (null !== $depth) {
            $data = $data->withMaxDepth($depth);
        }

        // Work around https://github.com/symfony/symfony/issues/23572
        $oldLocale = \setlocale(LC_NUMERIC, 0);
        \setlocale(LC_NUMERIC, 'C');

        $output = '';
        $this->dumper->dump($data, function ($line, $depth) use (&$output) {
            if ($depth >= 0) {
                if ('' !== $output) {
                    $output .= PHP_EOL;
                }
                $output .= \str_repeat('  ', $depth) . $line;
            }
        });

        // Now put the locale back
        \setlocale(LC_NUMERIC, $oldLocale);

        return OutputFormatter::escape($output);
    }
157384
public function writeValueToMappingResult($value, MappingResult $mappingResult, N2nContext $n2nContext) {
		if ($this->isArray()) {
			$mapValue = $this->createEmptyValue();
			
			if ($value !== null) {
				ArgUtils::valArrayLike($value);
				foreach ($value as $key => $valueField) {
					$mapValue[$key] = $this->createMappingResult($valueField, $n2nContext);
				}
			}
			 
			$mappingResult->__set($this->getName(), $mapValue);
			return;
		}

		if ($value !== null) {
			$mappingResult->__set($this->getName(), $this->createMappingResult($value, $n2nContext));
			return;
		}
		
		$mappingResult->__set($this->getName(), null);
	}
1037703
protected function process_value( $value, $output ) {
		if ( isset( $output['property'] ) ) {
			return $this->process_property_value( $output['property'], $value );
		}
		return $value;
	}
743478
function Write($h, $txt, $currentx = 0, $link = '', $directionality = 'ltr', $align = '', $fill = 0)
	{
		if (empty($this->directWrite)) {
			$this->directWrite = new DirectWrite($this, $this->otl, $this->sizeConverter, $this->colorConverter);
		}

		$this->directWrite->Write($h, $txt, $currentx, $link, $directionality, $align, $fill);
	}
704606
public function output($value = null)
    {
        $value = is_null($value) ? $this->value : $value;

        return $this->isRepeatable()
            ? $this->outputRepeatable().$this->getExplanation()
            : $this->outputInput($value).$this->getExplanation();
    }
1055239
public function writeValue($key, $value) {
        $property_cache = static::initPropertyCache($this);
        if(!array_key_exists($key, $property_cache["setter"])) {
            return FALSE;
        }

        $setter = $property_cache["setter"][$key];

        if(is_string($setter)) {
            $this->$key = $value;
        }
        else {
            call_user_func_array([$this, $setter[0]], [$value]);
        }

        return TRUE;
    }
543967
public function write($contents)
	{
		if($this->output != '')
		{
			$this->buffer .= "\t\t\$out->write(" . var_export($this->output, true) .  ");\n";
			$this->output = '';
		}
		
		$this->buffer .= $contents;
	}
1102284
public function writeToTemplate($value)
	{

		if (is_array($this->arrMapper))
		{
			$arrValue[$this->arrMapper[0]] = $this->Template->{$this->arrMapper[0]};
			
			$map =& $arrValue;
			
			foreach ($this->arrMapper as $key)
			{
				if (!is_array($map[$key]))
				{
					$map[$key] = array();
				}
				
				$map =& $map[$key];
			}
			
			$map[$this->alias] = $value;

			$this->Template->{$this->arrMapper[0]} = $arrValue[$this->arrMapper[0]];
			return;
		}	
	
		$this->Template->{$this->alias} = $value;
	}
639601
public function setQuotedPrintableValue($val)
    {
        $val = quoted_printable_decode($val);

        // Quoted printable only appears in vCard 2.1, and the only character
        // that may be escaped there is ;. So we are simply splitting on just
        // that.
        //
        // We also don't have to unescape \\, so all we need to look for is a ;
        // that's not preceeded with a \.
        $regex = '# (?<!\\\\) ; #x';
        $matches = preg_split($regex, $val);
        $this->setValue($matches);
    }
480226
private static function doWith(Params $ret, $key, $value, $multiple = true)
    {
        if (!$multiple) {
            if (!is_scalar($value)) {
                throw new \InvalidArgumentException(
                    'Invalid argument $value to with(), expected scalar, got ' . gettype($value)
                );
            }
            if ($ret->contains($key, $value)) {
                $ret->remove($key, $value);
            } else {
                $ret->replace($key, [$value]);
            }
        } else {
            if ($ret->contains($key, $value)) {
                $ret->remove($key, $value);
            } else {
                $ret->add($key, $value);
            }
        }

        return $ret;
    }