Fixed missed documentation issues in Doctrine\ORM
This commit is contained in:
parent
aadce3c747
commit
774bb3fec4
@ -27,6 +27,9 @@ namespace Doctrine\ORM;
|
||||
*/
|
||||
class EntityNotFoundException extends ORMException
|
||||
{
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct('Entity was not found.');
|
||||
|
@ -30,9 +30,28 @@ use Doctrine\ORM\EntityManager;
|
||||
*/
|
||||
class SequenceGenerator extends AbstractIdGenerator implements Serializable
|
||||
{
|
||||
/**
|
||||
* The allocation size of the sequence.
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
private $_allocationSize;
|
||||
|
||||
/**
|
||||
* The name of the sequence.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
private $_sequenceName;
|
||||
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
private $_nextValue = 0;
|
||||
|
||||
/**
|
||||
* @var int|null
|
||||
*/
|
||||
private $_maxValue = null;
|
||||
|
||||
/**
|
||||
@ -53,7 +72,7 @@ class SequenceGenerator extends AbstractIdGenerator implements Serializable
|
||||
* @param EntityManager $em
|
||||
* @param object $entity
|
||||
*
|
||||
* @return integer|float The generated value.
|
||||
* @return integer The generated value.
|
||||
*
|
||||
* @override
|
||||
*/
|
||||
@ -74,7 +93,7 @@ class SequenceGenerator extends AbstractIdGenerator implements Serializable
|
||||
/**
|
||||
* Gets the maximum value of the currently allocated bag of values.
|
||||
*
|
||||
* @return integer|float
|
||||
* @return integer|null
|
||||
*/
|
||||
public function getCurrentMaxValue()
|
||||
{
|
||||
@ -84,7 +103,7 @@ class SequenceGenerator extends AbstractIdGenerator implements Serializable
|
||||
/**
|
||||
* Gets the next value that will be returned by generate().
|
||||
*
|
||||
* @return integer|float
|
||||
* @return integer
|
||||
*/
|
||||
public function getNextValue()
|
||||
{
|
||||
|
@ -47,7 +47,14 @@ class TableGenerator extends AbstractIdGenerator
|
||||
*/
|
||||
private $_allocationSize;
|
||||
|
||||
/**
|
||||
* @var int|null
|
||||
*/
|
||||
private $_nextValue;
|
||||
|
||||
/**
|
||||
* @var int|null
|
||||
*/
|
||||
private $_maxValue;
|
||||
|
||||
/**
|
||||
|
@ -610,6 +610,8 @@ class ObjectHydrator extends AbstractHydrator
|
||||
* When executed in a hydrate() loop we may have to clear internal state to
|
||||
* decrease memory consumption.
|
||||
*
|
||||
* @param mixed $eventArgs
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function onClear($eventArgs)
|
||||
|
@ -27,6 +27,9 @@ namespace Doctrine\ORM;
|
||||
*/
|
||||
class NoResultException extends UnexpectedResultException
|
||||
{
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct('No result was found for query although at least one row was expected.');
|
||||
|
@ -705,7 +705,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
/* ArrayAccess implementation */
|
||||
|
||||
/**
|
||||
* @see containsKey()
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function offsetExists($offset)
|
||||
{
|
||||
@ -713,7 +713,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* @see get()
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function offsetGet($offset)
|
||||
{
|
||||
@ -721,8 +721,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* @see add()
|
||||
* @see set()
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function offsetSet($offset, $value)
|
||||
{
|
||||
@ -734,20 +733,23 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* @see remove()
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function offsetUnset($offset)
|
||||
{
|
||||
return $this->remove($offset);
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function key()
|
||||
{
|
||||
return $this->coll->key();
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the element of the collection at the current iterator position.
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function current()
|
||||
{
|
||||
@ -755,7 +757,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* Moves the internal iterator position to the next element.
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function next()
|
||||
{
|
||||
@ -773,7 +775,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* Extract a slice of $length elements starting at position $offset from the Collection.
|
||||
* Extracts a slice of $length elements starting at position $offset from the Collection.
|
||||
*
|
||||
* If $length is null it returns all elements from $offset to the end of the Collection.
|
||||
* Keys have to be preserved by this method. Calling this method will only return the
|
||||
@ -798,7 +800,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* Cleanup internal state of cloned persistent collection.
|
||||
* Cleans up internal state of cloned persistent collection.
|
||||
*
|
||||
* The following problems have to be prevented:
|
||||
* 1. Added entities are added to old PC
|
||||
@ -825,7 +827,7 @@ final class PersistentCollection implements Collection, Selectable
|
||||
}
|
||||
|
||||
/**
|
||||
* Select all elements from a selectable that match the expression and
|
||||
* Selects all elements from a selectable that match the expression and
|
||||
* return a new collection containing these elements.
|
||||
*
|
||||
* @param \Doctrine\Common\Collections\Criteria $criteria
|
||||
@ -866,4 +868,3 @@ final class PersistentCollection implements Collection, Selectable
|
||||
return new ArrayCollection(array_merge($persister->loadCriteria($criteria), $newObjects));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -299,6 +299,9 @@ public function __construct()
|
||||
}
|
||||
';
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
if (version_compare(\Doctrine\Common\Version::VERSION, '2.2.0-DEV', '>=')) {
|
||||
@ -439,6 +442,8 @@ public function __construct()
|
||||
/**
|
||||
* Sets the name of the class the generated classes should extend from.
|
||||
*
|
||||
* @param string $classToExtend
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function setClassToExtend($classToExtend)
|
||||
|
Loading…
Reference in New Issue
Block a user