downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

JsonSerializable::jsonSerialize> <Stałe predefiniowane
[edit] Last updated: Fri, 23 Mar 2012

view this page in

The JsonSerializable interface

(PHP 5 >= 5.4.0)

Wstęp

Objects implementing JsonSerializable can customize their JSON representation when encoded with json_encode().

Zestawienie interfejsu

JsonSerializable {
/* Metody */
abstract public mixed jsonSerialize ( void )
}

Spis treści



add a note add a note User Contributed Notes JsonSerializable
Webdev 29-Apr-2012 02:36
The "encode everything in my class"-Code:

public function jsonSerialize()
{
    return get_object_vars($this);
}

 
show source | credits | stats | sitemap | contact | advertising | mirror sites