public function save($object)
    {
        if (method_exists($object, 'getContenttype')) {
            $entityName = $object->getContenttype();
        } else {
            $entityName = get_class($object);
        }
        $repo = $this->getRepository($entityName);

        return $repo->save($object);
    }
public function save($object)
    {
        if (method_exists($object, 'getContenttype')) {
            $entityName = $object->getContenttype();
        } else {
            $entityName = get_class($object);
        }
        $repo = $this->getRepository($entityName);

        return $repo->save($object);
    }
public function save ( $ object ) { if ( method_exists ( $ object , 'getContenttype' ) ) { $ entityName = $ object -> getContenttype ( ) ; } else { $ entityName = get_class ( $ object ) ; } $ repo = $ this -> getRepository ( $ entityName ) ; return $ repo -> save ( $ object ) ; }
The object will be entered into the database as a result of this operation.

@param object $object the instance to persist to storage

@throws InvalidRepositoryException

@return bool
The object will be entered into the database as a result of this operation .