Serializable implementation: serialize

@return  array  model data
490183
public function serialize()
	{
		$data = $this->_data;

		$data['_is_new'] = $this->_is_new;
		$data['_is_frozen'] = $this->_is_frozen;

		return serialize($data);
	}
738012
public function toArray()
	{
		return [
			'name' => (string) $this->name,
			'email' => SerializationHelper::serialize($this->email),
			'links' => SerializationHelper::serialize($this->links)
		];
	}
1198589
protected function get_data_to_serialize() {
		return array(
			'recipient'    => $this->recipient->ID,
			'message'      => $this->message,
			'subject'      => $this->subject,
			'strategy'     => $this->strategy,
			'manager'      => $this->manager->get_type(),
			'data_sources' => $this->data_sources
		);
	}
688907
public function serialize()
    {
        // Load all of the inputs.
        $this->loadAllInputs();

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

        // Serialize the executable, args, options, data, and inputs.
        return serialize([$this->calledScript, $this->args, $this->filter, $this->data, $inputs]);
    }
748350
public function serialize()
    {
        return serialize(array(
            'credentials'   => $this->credentials,
            'loginResult'   => $this->loginResult,
            'debug'         => $this->debug,
            'lastLoginTime' => $this->lastLoginTime,
            '__parentData'  => parent::serialize()
        ));
    }
1017672
public function serialize()
    {
        $result = [
            'code' => $this->getCode(),
            'message' => $this->getMessage(),
            'errors' => $this->getErrors()
        ];

        $result['data'] = $this->getVariables();

        if ($result['data'] instanceof Traversable) {
            $result['data'] = ArrayUtils::iteratorToArray($result['data']);
        }

        if (null !== $this->jsonpCallback) {
            return $this->jsonpCallback . '(' . Json::encode($result) . ');';
        }

        return Json::encode($result);
    }
601644
public function serialize()
    {
        // Only serialize long term cookies and unexpired cookies
        return json_encode(array_map(function (Cookie $cookie) {
            return $cookie->toArray();
        }, $this->all(null, null, null, true, true)));
    }
596657
public function jsonSerialize()
    {
        $data = [];

        foreach ($this as $element) {
            if ($element instanceof \JsonSerializable) {
                $data[] = $element->jsonSerialize();
            }
        }

        return $data;
    }
227211
public function serialize()
    {
        return serialize([
            $this->path,
            $this->schemes,
            $this->methods,
            $this->defaults,
            $this->constraints,
            $this->parts,
            $this->compiled,
        ]);
    }
224129
public function serialize() {
		$attributes = array();

		if ( $this->visible ) {
			// If visible attributes are set, we'll only reveal those.
			foreach ( $this->visible as $key ) {
				$attributes[ $key ] = $this->get_attribute( $key );
			}
		} elseif ( $this->hidden ) {
			// If hidden attributes are set, we'll grab everything and hide those.
			foreach ( $this->get_attribute_keys() as $key ) {
				if ( ! in_array( $key, $this->hidden ) ) {
					$attributes[ $key ] = $this->get_attribute( $key );
				}
			}
		} else {
			// If nothing is hidden/visible, we'll grab and reveal everything.
			foreach ( $this->get_attribute_keys() as $key ) {
				$attributes[ $key ] = $this->get_attribute( $key );
			}
		}

		return array_map( function ( $attribute ) {
			if ( $attribute instanceof Serializes ) {
				return $attribute->serialize();
			}

			return $attribute;
		}, $attributes );
	}
363917
public function serialize() {
		return $this->map(function( $element ) {
			if ( $element instanceof Serializes ) {
				return $element->serialize();
			}

			return $element;
		} )->to_array();
	}
1014580
public function serialize()
    {
        return base64_encode(json_encode([
            'sessionName' => $this->session->name(),
            'transactionId' => $this->transactionId,
            'readTimestamp' => $this->readTimestamp->formatAsString()
        ]));
    }
632352
public function serialize()
    {
        $unitOfWork       = $this->getManager()->getUnitOfWork();
        $simpleReferences = [];

        foreach ($this->getReferences() as $name => $reference) {
            $className = $this->getRealClass(get_class($reference));

            $simpleReferences[$name] = [$className, $this->getIdentifier($reference, $unitOfWork)];
        }

        $serializedData = json_encode([
            'references' => $simpleReferences,
            'identities' => $this->getIdentities(),
        ]);

        return $serializedData;
    }
537509
public function toArray()
	{
		return [
			'creator' => SerializationHelper::stringOrNull($this->creator),
			'metadata' => SerializationHelper::serialize($this->metadata),
			'waypoints' => SerializationHelper::serialize($this->waypoints),
			'routes' => SerializationHelper::serialize($this->routes),
			'tracks' => SerializationHelper::serialize($this->tracks),
			'extensions' => SerializationHelper::serialize($this->extensions)
		];
	}
392981
public function serialize()
    {
        return serialize([
            'username' => $this->username,
            'password' => $this->password,
            'logQueries' => $this->logQueries,
            'options' => $this->options,
            'commands' => $this->commands,
            'dsn' => $this->dsn,
        ]);
    }
1029617
public function serialize()
    {
        return serialize([
            $this->id,
            $this->password,
            $this->email,
            $this->isActive,
            $this->lastLogin,
            $this->createdAt,
        ]);
    }
95772
public function serialize()
    {

        @\pg_close($this->_connection);

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

        return serialize($data);
    }