Location: PHPKode > projects > MongoDB Object Document Mapper > tests/Documents/Group.php
<?php

namespace Documents;

use Doctrine\ODM\MongoDB\Mapping\ClassMetadata;

/** @Document(db="doctrine_odm_tests", collection="groups") */
class Group
{
    /** @Id */
    private $id;

    /** @Field */
    private $name;

    public function __construct($name = null)
    {
        $this->name = $name;
    }

    public function getId()
    {
        return $this->id;
    }

    public function setName($name)
    {
        $this->name = $name;
    }

    public function getName()
    {
        return $this->name;
    }
}
Return current item: MongoDB Object Document Mapper