Serialize a dataType
@return string
541480
public function serialize()
    {
        $output = array();
        foreach( $this->data as $key => $value ) {
            if( !array_key_exists( $key, static::$defaults ) or static::$defaults[$key] !== $value ) {
                $output[$key] = $value;
            }
        }
        return json_encode(
            array(
                $this->name,
                $this->entity,
                $this->fullyQualifiedName,
                $output
            )
        );
    }
2782
public function serializeToString()
    {
        $output = new CodedOutputStream($this->byteSize());
        $this->serializeToStream($output);
        return $output->getData();
    }
146582
public function serialize_properties()
    {
        if (!empty($this->serialized_properties)) {
            return $this->serialized_properties;
        }

        $shift = 15;
        $flag_bits = 0;
        $flags = array();
        $raw_bytes = new AMQPWriter();

        foreach ($this->prop_types as $key => $prototype) {
            $val = isset($this->properties[$key]) ? $this->properties[$key] : null;

            // Very important: PHP type eval is weak, use the === to test the
            // value content. Zero or false value should not be removed
            if ($val === null) {
                $shift -= 1;
                continue;
            }

            if ($shift === 0) {
                $flags[] = $flag_bits;
                $flag_bits = 0;
                $shift = 15;
            }

            $flag_bits |= (1 << $shift);
            if ($prototype != 'bit') {
                $raw_bytes->{'write_' . $prototype}($val);
            }

            $shift -= 1;
        }

        $flags[] = $flag_bits;
        $result = new AMQPWriter();
        foreach ($flags as $flag_bits) {
            $result->write_short($flag_bits);
        }

        $result->write($raw_bytes->getvalue());

        $this->serialized_properties = $result->getvalue();

        return $this->serialized_properties;
    }
891730
public function serialize()
    {
        return serialize(
            [
                $this->outFilePath,
                $this->width,
                $this->height,
                $this->frameRate,
                $this->loopCount,
                $this->gifData,
                $this->frames,
                $this->counter,
            ]
        );
    }
162073
public function serialize()
	{
		return serialize(array(	$this->pemFile,
								$this->passphrase,
								$this->endpointEnv,

								$this->isValidated,
								$this->description,
								$this->validFrom,
								$this->validTo));
	}
168838
public function jsonSerialize()
    {
        $attributes = $this->getAttributes();

        array_walk_recursive($attributes, function(&$val) {
            if (MbString::isLoaded()) {
                // If we're able to detect the attribute
                // encoding, we'll encode only the
                // attributes that need to be.
                if (! MbString::isUtf8($val)) {
                    $val = utf8_encode($val);
                }
            } else {
                // If the mbstring extension is not loaded, we'll
                // encode all attributes to make sure
                // they are encoded properly.
                $val = utf8_encode($val);
            }
        });

        // We'll replace the binary GUID and SID with
        // their string equivalents for convenience.
        return array_replace($attributes, [
            $this->schema->objectGuid() => $this->getConvertedGuid(),
            $this->schema->objectSid() => $this->getConvertedSid(),
        ]);
    }
1154226
public function serialize()
    {
        return serialize(
            array(
                $this->providerID,
                $this->authenticationServiceName,
                $this->sessionIndex,
                $this->nameID,
                $this->nameIDFormat,
                $this->createdOn,
            )
        );
    }
22097
public function serialize()
	{
		return serialize( array( $this->message, $this->code, $this->file, $this->line, $this->errors, $this->form ) );
	}
1043555
public function serialize(){

		@mysqli_close($this->_connection);

		$data = [
			$this->_server,
			$this->_username,
			$this->_password,
			$this->_database
		];

		return serialize($data);
	}
292786
public function serialize()
    {
        // @codingStandardsIgnoreStart
        unset($this->inspector, $this->___mocked);
        // @codingStandardsIgnoreEnd
        $keys = array_keys(get_object_vars($this));
        $data = [];
        foreach ($keys as $key) {
            $data[$key] = $this->$key;
        }
        return serialize($data);
    }
563278
public function toString()
    {
        $output = 'data:';

        if (($this->getMediaType() !== self::DEFAULT_TYPE) || ($this->getEncoding() !== self::ENCODING_URL_ENCODED_OCTETS)) {
            $output .= $this->getMediaType();

            if ($this->getEncoding() === self::ENCODING_BASE64) {
                $output .= ';'.self::BASE64_KEYWORD;
            }
        }

        $output .= ','.$this->getEncodedData();

        return $output;
    }
1174994
public function serialize()
    {
        $data = array(
            'coverage'      => $this->coverage,
            'filter'        => $this->filter,
            'options'       => $this->options,
            'path'          => $this->path,
        );

        return serialize($data);
    }
1035613
public function serializeData()
    {
        if (isset($this->_dataObject)) {
            try {
                $this->result = serialize($this->_dataObject);
            } catch (\Exception $e) {
                \d($this->_dataObject);
                exit;
            }
        }
    }
185188
public function serialize()
	{
		// Load all of the inputs.
		$this->loadAllInputs();

		// Remove $_ENV and $_SERVER from the inputs.
		$inputs = $this->inputs;
		unset($inputs['env'], $inputs['server']);

		// Serialize the executable, args, options, data, and inputs.
		return serialize(array($this->executable, $this->args, $this->options, $this->data, $inputs));
	}
1014580
public function serialize()
    {
        return base64_encode(json_encode([
            'sessionName' => $this->session->name(),
            'transactionId' => $this->transactionId,
            'readTimestamp' => $this->readTimestamp->formatAsString()
        ]));
    }
59848
public function serialize()
    {
        return serialize(array($this->name, $this->value, $this->code, $this->line));
    }
1066950
public function serialize()
    {
        $data = array();

        $skip = array(
            'connection',
            'platform',
            'driver'
        );

        foreach ($this as $key => $value) {
            if (in_array($key, $skip)) {
                continue;
            }
            $data[$key] = $value;
        }

        return serialize($data);
    }