public function generateEntityClass(EntityMetadata $meta)
    {
        $placeholders = array(
            '<namespace>',
            '<classAnnotations>',
            '<className>',
            '<implements>',
            '<traits>'
        );

        $replacements = array(
            $this->namespace,
            $this->generateClassAnnotations($meta->getTraits()),
            $meta->getClassName(),
            $this->generateImplements($meta->getInterfaces()),
            $this->generateTraitStatements($meta->getTraits())
        );

        $code = str_replace($placeholders, $replacements, self::$template);
        return str_replace('<spaces>', self::$spaces, $code);
    }