Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misc. code doc updates #2773

Merged
merged 2 commits into from
Feb 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 7 additions & 9 deletions src/Blameable/Blameable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\Blameable;

/**
* This interface is not necessary but can be implemented for
* Entities which in some cases needs to be identified as
* Blameable
* Marker interface for objects which can be identified as blamable.
*
* @author Gediminas Morkevicius <gediminas.morkevicius@gmail.com>
*/
Expand All @@ -21,35 +19,35 @@ interface Blameable
// blameable expects annotations on properties

/*
* @gedmo:Blameable(on="create")
* @Gedmo\Blameable(on="create")
* fields which should be updated on insert only
*/

/*
* @gedmo:Blameable(on="update")
* @Gedmo\Blameable(on="update")
* fields which should be updated on update and insert
*/

/*
* @gedmo:Blameable(on="change", field="field", value="value")
* @Gedmo\Blameable(on="change", field="field", value="value")
* fields which should be updated on changed "property"
* value and become equal to given "value"
*/

/*
* @gedmo:Blameable(on="change", field="field")
* @Gedmo\Blameable(on="change", field="field")
* fields which should be updated on changed "property"
*/

/*
* @gedmo:Blameable(on="change", fields={"field1", "field2"})
* @Gedmo\Blameable(on="change", fields={"field1", "field2"})
* fields which should be updated if at least one of the given fields changed
*/

/*
* example
*
* @gedmo:Blameable(on="create")
* @Gedmo\Blameable(on="create")
* @Column(type="string")
* $created
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Blameable/Traits/Blameable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
namespace Gedmo\Blameable\Traits;

/**
* Blameable Trait, usable with PHP >= 5.4
* Trait for blamable objects.
*
* This implementation does not provide any mapping configurations.
*
* @author David Buchmann <mail@davidbu.ch>
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Blameable/Traits/BlameableDocument.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@
use Gedmo\Mapping\Annotation as Gedmo;

/**
* Blameable Trait, usable with PHP >= 5.4
* Trait for blamable objects.
*
* This implementation provides a mapping configuration for the Doctrine MongoDB ODM.
*
* @author David Buchmann <mail@davidbu.ch>
*/
Expand Down
4 changes: 3 additions & 1 deletion src/Blameable/Traits/BlameableEntity.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
use Gedmo\Mapping\Annotation as Gedmo;

/**
* Blameable Trait, usable with PHP >= 5.4
* Trait for blamable objects.
*
* This implementation provides a mapping configuration for the Doctrine ORM.
*
* @author David Buchmann <mail@davidbu.ch>
*/
Expand Down
16 changes: 7 additions & 9 deletions src/IpTraceable/IpTraceable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\IpTraceable;

/**
* This interface is not necessary but can be implemented for
* Entities which in some cases needs to be identified as
* IpTraceable
* Marker interface for objects which can be identified as IP traceable.
*
* @author Pierre-Charles Bertineau <pc.bertineau@alterphp.com>
*/
Expand All @@ -21,35 +19,35 @@ interface IpTraceable
// ipTraceable expects annotations on properties

/*
* @gedmo:IpTraceable(on="create")
* @Gedmo\IpTraceable(on="create")
* strings which should be updated on insert only
*/

/*
* @gedmo:IpTraceable(on="update")
* @Gedmo\IpTraceable(on="update")
* strings which should be updated on update and insert
*/

/*
* @gedmo:IpTraceable(on="change", field="field", value="value")
* @Gedmo\IpTraceable(on="change", field="field", value="value")
* strings which should be updated on changed "property"
* value and become equal to given "value"
*/

/*
* @gedmo:IpTraceable(on="change", field="field")
* @Gedmo\IpTraceable(on="change", field="field")
* strings which should be updated on changed "property"
*/

/*
* @gedmo:IpTraceable(on="change", fields={"field1", "field2"})
* @Gedmo\IpTraceable(on="change", fields={"field1", "field2"})
* strings which should be updated if at least one of the given fields changed
*/

/*
* example
*
* @gedmo:IpTraceable(on="create")
* @Gedmo\IpTraceable(on="create")
* @Column(type="string")
* $created
*/
Expand Down
4 changes: 3 additions & 1 deletion src/IpTraceable/Traits/IpTraceable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
namespace Gedmo\IpTraceable\Traits;

/**
* IpTraceable Trait, usable with PHP >= 5.4
* Trait for IP traceable objects.
*
* This implementation does not provide any mapping configurations.
*
* @author Pierre-Charles Bertineau <pc.bertineau@alterphp.com>
*/
Expand Down
4 changes: 3 additions & 1 deletion src/IpTraceable/Traits/IpTraceableDocument.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@
use Gedmo\Mapping\Annotation as Gedmo;

/**
* IpTraceable Trait, usable with PHP >= 5.4
* Trait for IP traceable objects.
*
* This implementation provides a mapping configuration for the Doctrine MongoDB ODM.
*
* @author Pierre-Charles Bertineau <pc.bertineau@alterphp.com>
*/
Expand Down
4 changes: 3 additions & 1 deletion src/IpTraceable/Traits/IpTraceableEntity.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
use Gedmo\Mapping\Annotation as Gedmo;

/**
* IpTraceable Trait, usable with PHP >= 5.4
* Trait for IP traceable objects.
*
* This implementation provides a mapping configuration for the Doctrine ORM.
*
* @author Pierre-Charles Bertineau <pc.bertineau@alterphp.com>
*/
Expand Down
10 changes: 4 additions & 6 deletions src/Loggable/Loggable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\Loggable;

/**
* This interface is not necessary but can be implemented for
* Domain Objects which in some cases needs to be identified as
* Loggable
* Marker interface for objects which can be identified as loggable.
*
* @author Gediminas Morkevicius <gediminas.morkevicius@gmail.com>
*/
Expand All @@ -21,14 +19,14 @@ interface Loggable
// this interface is not necessary to implement

/*
* @gedmo:Loggable
* to mark the class as loggable use class annotation @gedmo:Loggable
* @Gedmo\Loggable
* to mark the class as loggable use class annotation @Gedmo\Loggable
* this object will contain now a history
* available options:
* logEntryClass="My\LogEntryObject" (optional) defaultly will use internal object class
* example:
*
* @gedmo:Loggable(logEntryClass="My\LogEntryObject")
* @Gedmo\Loggable(logEntryClass="My\LogEntryObject")
* class MyEntity
*/
}
4 changes: 1 addition & 3 deletions src/ReferenceIntegrity/ReferenceIntegrity.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\ReferenceIntegrity;

/**
* This interface is not necessary but can be implemented for
* Entities which in some cases needs to be identified te have
* ReferenceIntegrity checks
* Marker interface for objects which can be identified as requiring reference integrity checks.
*
* @author Evert Harmeling <evert.harmeling@freshheads.com>
*/
Expand Down
12 changes: 5 additions & 7 deletions src/Sluggable/Sluggable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\Sluggable;

/**
* This interface is not necessary but can be implemented for
* Entities which in some cases needs to be identified as
* Sluggable
* Marker interface for objects which can be identified as sluggable.
*
* @author Gediminas Morkevicius <gediminas.morkevicius@gmail.com>
*/
Expand All @@ -21,13 +19,13 @@ interface Sluggable
// use now annotations instead of predefined methods, this interface is not necessary

/*
* @gedmo:Sluggable
* to mark the field as sluggable use property annotation @gedmo:Sluggable
* @Gedmo\Sluggable
* to mark the field as sluggable use property annotation @Gedmo\Sluggable
* this field value will be included in built slug
*/

/*
* @gedmo:Slug - to mark property which will hold slug use annotation @gedmo:Slug
* @Gedmo\Slug - to mark property which will hold slug use annotation @Gedmo\Slug
* available options:
* updatable (optional, default=true) - true to update the slug on sluggable field changes, false - otherwise
* unique (optional, default=true) - true if slug should be unique and if identical it will be prefixed, false - otherwise
Expand All @@ -40,7 +38,7 @@ interface Sluggable
*
* example:
*
* @gedmo:Slug(style="camel", separator="_", prefix="", suffix="", updatable=false, unique=false)
* @Gedmo\Slug(style="camel", separator="_", prefix="", suffix="", updatable=false, unique=false)
* @Column(type="string", length=64)
* $property
*/
Expand Down
10 changes: 4 additions & 6 deletions src/SoftDeleteable/SoftDeleteable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\SoftDeleteable;

/**
* This interface is not necessary but can be implemented for
* Domain Objects which in some cases needs to be identified as
* SoftDeleteable
* Marker interface for objects which can be identified as soft-deletable.
*
* @author Gustavo Falco <comfortablynumb84@gmail.com>
* @author Gediminas Morkevicius <gediminas.morkevicius@gmail.com>
Expand All @@ -22,12 +20,12 @@ interface SoftDeleteable
// this interface is not necessary to implement

/*
* @gedmo:SoftDeleteable
* to mark the class as SoftDeleteable use class annotation @gedmo:SoftDeleteable
* @Gedmo\SoftDeleteable
* to mark the class as SoftDeleteable use class annotation @Gedmo\SoftDeleteable
* this object will be able to be soft deleted
* example:
*
* @gedmo:SoftDeleteable
* @Gedmo\SoftDeleteable
* class MyEntity
*/
}
5 changes: 3 additions & 2 deletions src/SoftDeleteable/Traits/SoftDeleteable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@
namespace Gedmo\SoftDeleteable\Traits;

/**
* A generic trait to use on your self-deletable entities.
* There is no mapping information defined in this trait.
* Trait for soft-deletable objects.
*
* This implementation does not provide any mapping configurations.
*
* @author Wesley van Opdorp <wesley.van.opdorp@freshheads.com>
*/
Expand Down
5 changes: 3 additions & 2 deletions src/SoftDeleteable/Traits/SoftDeleteableDocument.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
use Doctrine\ODM\MongoDB\Types\Type;

/**
* A soft deletable trait you can apply to your MongoDB entities.
* Includes default annotation mapping.
* Trait for soft-deletable objects.
*
* This implementation provides a mapping configuration for the Doctrine MongoDB ODM.
*
* @author Wesley van Opdorp <wesley.van.opdorp@freshheads.com>
*/
Expand Down
5 changes: 3 additions & 2 deletions src/SoftDeleteable/Traits/SoftDeleteableEntity.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,9 @@
use Doctrine\ORM\Mapping as ORM;

/**
* A soft deletable trait you can apply to your Doctrine ORM entities.
* Includes default annotation mapping.
* Trait for soft-deletable objects.
*
* This implementation provides a mapping configuration for the Doctrine ORM.
*
* @author Wesley van Opdorp <wesley.van.opdorp@freshheads.com>
*/
Expand Down
14 changes: 6 additions & 8 deletions src/Sortable/Sortable.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
namespace Gedmo\Sortable;

/**
* This interface is not necessary but can be implemented for
* Entities which in some cases needs to be identified as
* Sortable
* Marker interface for objects which can be identified as sortable.
*
* @author Lukas Botsch <lukas.botsch@gmail.com>
*/
Expand All @@ -21,27 +19,27 @@ interface Sortable
// use now annotations instead of predefined methods, this interface is not necessary

/*
* @gedmo:SortablePosition - to mark property which will hold the item position use annotation @gedmo:SortablePosition
* @Gedmo\SortablePosition - to mark property which will hold the item position use annotation @Gedmo\SortablePosition
* This property has to be numeric. The position index can be negative and will be counted from right to left.
*
* example:
*
* @gedmo:SortablePosition
* @Gedmo\SortablePosition
* @Column(type="int")
* $position
*
* @gedmo:SortableGroup
* @Gedmo\SortableGroup
* @Column(type="string", length=64)
* $category
*
*/

/*
* @gedmo:SortableGroup - to group node sorting by a property use annotation @gedmo:SortableGroup on this property
* @Gedmo\SortableGroup - to group node sorting by a property use annotation @Gedmo\SortableGroup on this property
*
* example:
*
* @gedmo:SortableGroup
* @Gedmo\SortableGroup
* @Column(type="string", length=64)
* $category
*/
Expand Down
Loading
Loading