src/Sulu/Bundle/SearchBundle/Search/Document.php
public function removeSystemFields()
    {
        $properties = $this->fields;
        unset(
            $properties['created'],
            $properties['changed'],
            $properties['changer'],
            $properties['changer_id'],
            $properties['creator'],
            $properties['creator_id']
        );

        foreach ($properties as $key => $field) {
            // remove system fields
            if ('__' == substr($key, 0, 2)) {
                continue;
            }

            $this->properties[$key] = $field->getValue();
        }
    }
public function removeSystemFields()
    {
        $properties = $this->fields;
        unset(
            $properties['created'],
            $properties['changed'],
            $properties['changer'],
            $properties['changer_id'],
            $properties['creator'],
            $properties['creator_id']
        );

        foreach ($properties as $key => $field) {
            // remove system fields
            if ('__' == substr($key, 0, 2)) {
                continue;
            }

            $this->properties[$key] = $field->getValue();
        }
    }
public function removeSystemFields ( ) { $ properties = $ this -> fields ; unset ( $ properties [ 'created' ] , $ properties [ 'changed' ] , $ properties [ 'changer' ] , $ properties [ 'changer_id' ] , $ properties [ 'creator' ] , $ properties [ 'creator_id' ] ) ; foreach ( $ properties as $ key => $ field ) { // remove system fields if ( '__' == substr ( $ key , 0 , 2 ) ) { continue ; } $ this -> properties [ $ key ] = $ field -> getValue ( ) ; } }
Called by the JMS Serializer before the document is serialized for the
web API.

Here we remove all system fields (which are available in the body
of the document anyway).
Called by the JMS Serializer before the document is serialized for the web API .