ezsystems/ezp-next — pull request #1 by patrickallaert (2011-12-22 11:15:57+00:00)
Title: Added: dump feature as a var_dump() replacement

Calling the dump() method on an ezp\Content\Concrete object with a depth = 2 would display something like:

object(ezp\Content\Concrete) {
id: '108'
currentVersionNo: 1
status: NULL
ownerId: '14'
alwaysAvailable: false
remoteId: '17e526d5a6eed6da1053f784c6fc91d9'
sectionId: 1
typeId: 1
modified: 1324552107
published: 1324552107
initialLanguageId: 2
mainLocation: NULL
section:
object(ezp\Content\Section\Proxy) {
id:int(1)
}
owner:
object(ezp\User\Proxy) {
id:string(2) "14"
}
fields:
object(ezp\Content\Field\StaticCollection) {
type:string(17) "ezp\Content\Field"
elements array(5):
[name] =>
...
[short_description] =>
...
[short_name] =>
...
[description] =>
...
[show_children] =>
...
}
contentType:
object(ezp\Content\Type\Proxy) {
id:int(1)
}
versions:
object(ezp\Content\Version\LazyCollection) {
type:string(19) "ezp\Content\Version"
elements array(1):
[1] =>
...
}
locations:
object(ezp\Base\Collection\Type) {
type:string(20) "ezp\Content\Location"
elements array(0):
}
relations:
object(ezp\Base\Collection\Type) {
type:string(20) "ezp\Content\Relation"
elements array(0):
}
reverseRelations:
object(ezp\Base\Collection\Type) {
type:string(20) "ezp\Content\Relation"
elements array(0):
}
currentVersion:
object(ezp\Content\Version\Concrete) {
id: '609'
name: NULL
versionNo: 1
creatorId: '14'
created: 1324552107
modified: 1324552107
status: 0
contentId: '108'
initialLanguageId: 2
fields:
...
content:
...
ownerId: '14'
alwaysAvailable: false
remoteId: '17e526d5a6eed6da1053f784c6fc91d9'
sectionId: 1
typeId: 1
contentStatus: NULL
mainLocation: NULL
section:
...
owner:
...
contentType:
...
locations:
...
relations:
...
reverseRelations:
...
initialLanguage: NULL
}
initialLanguage: NULL
}