Skip to content

Commit

Permalink
Merge pull request #8480 from greg0ire/cs-20210216
Browse files Browse the repository at this point in the history
CS batch 11/an estimated 26
  • Loading branch information
greg0ire authored Feb 16, 2021
2 parents 30a7c2a + d76cbd7 commit ebae57e
Show file tree
Hide file tree
Showing 72 changed files with 222 additions and 48 deletions.
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/CMS/CmsAddress.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ class CmsAddress
public $street;

/**
* @var CmsUser
* @OneToOne(targetEntity="CmsUser", inversedBy="address")
* @JoinColumn(referencedColumnName="id")
*/
Expand Down
2 changes: 2 additions & 0 deletions tests/Doctrine/Tests/Models/CMS/CmsComment.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
class CmsComment
{
/**
* @var int
* @Column(type="integer")
* @Id
* @GeneratedValue(strategy="AUTO")
Expand All @@ -27,6 +28,7 @@ class CmsComment
*/
public $text;
/**
* @var CmsArticle
* @ManyToOne(targetEntity="CmsArticle", inversedBy="comments")
* @JoinColumn(name="article_id", referencedColumnName="id")
*/
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/CMS/CmsEmployee.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class CmsEmployee
private $name;

/**
* @var CmsEmployee
* @OneToOne(targetEntity="CmsEmployee")
* @JoinColumn(name="spouse_id", referencedColumnName="id")
*/
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/CMS/CmsPhonenumber.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ class CmsPhonenumber
/** @Id @Column(length=50) */
public $phonenumber;
/**
* @var CmsUser
* @ManyToOne(targetEntity="CmsUser", inversedBy="phonenumbers", cascade={"merge"})
* @JoinColumn(name="user_id", referencedColumnName="id")
*/
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/Cache/Login.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ class Login
public $name;

/**
* @var Token
* @ManyToOne(targetEntity="Token", cascade={"persist", "remove"}, inversedBy="logins")
* @JoinColumn(name="token_id", referencedColumnName="token")
*/
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/Company/CompanyManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ class CompanyManager extends CompanyEmployee
private $title;

/**
* @var CompanyCar
* @OneToOne(targetEntity="CompanyCar", cascade={"persist"})
* @JoinColumn(name="car_id", referencedColumnName="id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ class CustomIdObjectTypeChild
*/
public $id;

/** @ManyToOne(targetEntity="Doctrine\Tests\Models\CustomType\CustomIdObjectTypeParent", inversedBy="children") */
/**
* @var CustomIdObjectTypeParent
* @ManyToOne(targetEntity="Doctrine\Tests\Models\CustomType\CustomIdObjectTypeParent", inversedBy="children")
*/
public $parent;

public function __construct(CustomIdObject $id, CustomIdObjectTypeParent $parent)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ class DDC117ApproveChanges
private $id;

/**
* @var DDC117ArticleDetails
* @ManyToOne(targetEntity="DDC117ArticleDetails")
* @JoinColumn(name="details_id", referencedColumnName="article_id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ trait DDC1872ExampleTrait
protected $foo;

/**
* @var DDC1872Bar
* @OneToOne(targetEntity="DDC1872Bar", cascade={"persist", "merge"})
* @JoinColumn(name="example_trait_bar_id", referencedColumnName="id")
*/
Expand Down
2 changes: 2 additions & 0 deletions tests/Doctrine/Tests/Models/ECommerce/ECommerceCart.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
class ECommerceCart
{
/**
* @var int
* @Column(type="integer")
* @Id
* @GeneratedValue
Expand All @@ -26,6 +27,7 @@ class ECommerceCart
private $payment;

/**
* @var ECommerceCustomer
* @OneToOne(targetEntity="ECommerceCustomer", inversedBy="cart")
* @JoinColumn(name="customer_id", referencedColumnName="id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ class ECommerceCategory
private $children;

/**
* @var ECommerceCategory
* @ManyToOne(targetEntity="ECommerceCategory", inversedBy="children")
* @JoinColumn(name="parent_id", referencedColumnName="id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
class ECommerceCustomer
{
/**
* @var int
* @Column(type="integer")
* @Id
* @GeneratedValue(strategy="AUTO")
Expand Down
2 changes: 2 additions & 0 deletions tests/Doctrine/Tests/Models/ECommerce/ECommerceFeature.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
class ECommerceFeature
{
/**
* @var int
* @Column(type="integer")
* @Id
* @GeneratedValue
Expand All @@ -23,6 +24,7 @@ class ECommerceFeature
private $description;

/**
* @var ECommerceProduct
* @ManyToOne(targetEntity="ECommerceProduct", inversedBy="features")
* @JoinColumn(name="product_id", referencedColumnName="id")
*/
Expand Down
2 changes: 2 additions & 0 deletions tests/Doctrine/Tests/Models/ECommerce/ECommerceProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
class ECommerceProduct
{
/**
* @var int
* @Column(type="integer")
* @Id
* @GeneratedValue
Expand All @@ -29,6 +30,7 @@ class ECommerceProduct
private $name;

/**
* @var ECommerceShipping
* @OneToOne(targetEntity="ECommerceShipping", cascade={"persist"})
* @JoinColumn(name="shipping_id", referencedColumnName="id")
*/
Expand Down
5 changes: 4 additions & 1 deletion tests/Doctrine/Tests/Models/Forum/ForumAdministrator.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
*/
class ForumAdministrator extends ForumUser
{
/** @Column(type="integer", name="access_level") */
/**
* @var int
* @Column(type="integer", name="access_level")
*/
public $accessLevel;
}
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/Forum/ForumBoard.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class ForumBoard
*/
public $position;
/**
* @var ForumCategory
* @ManyToOne(targetEntity="ForumCategory", inversedBy="boards")
* @JoinColumn(name="category_id", referencedColumnName="id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
class NonAlphaColumnsEntity
{
/**
* @var int
* @Id
* @Column(type="integer", name="`simple-entity-id`")
* @GeneratedValue(strategy="AUTO")
Expand Down
6 changes: 5 additions & 1 deletion tests/Doctrine/Tests/Models/GeoNames/Admin1.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
class Admin1
{
/**
* @var int
* @Id
* @Column(type="integer", length=25)
* @GeneratedValue(strategy="NONE")
Expand All @@ -32,7 +33,10 @@ class Admin1
*/
public $names = [];

/** @Column(type="string", length=255); */
/**
* @var string
* @Column(type="string", length=255);
*/
public $name;

public function __construct($id, $name, Country $country)
Expand Down
5 changes: 4 additions & 1 deletion tests/Doctrine/Tests/Models/GeoNames/Admin1AlternateName.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@ class Admin1AlternateName
*/
public $admin1;

/** @Column(type="string", length=255); */
/**
* @var string
* @Column(type="string", length=255);
*/
public $name;

public function __construct($id, $name, Admin1 $admin1)
Expand Down
5 changes: 4 additions & 1 deletion tests/Doctrine/Tests/Models/GeoNames/City.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ class City
*/
public $admin1;

/** @Column(type="string", length=255); */
/**
* @var string
* @Column(type="string", length=255);
*/
public $name;

public function __construct($id, $name)
Expand Down
5 changes: 4 additions & 1 deletion tests/Doctrine/Tests/Models/GeoNames/Country.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@ class Country
*/
public $id;

/** @Column(type="string", length=255); */
/**
* @var string
* @Column(type="string", length=255);
*/
public $name;

public function __construct($id, $name)
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/Pagination/Logo.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class Logo
public $image_width;

/**
* @var Company
* @OneToOne(targetEntity="Company", inversedBy="logo", cascade={"persist"})
* @JoinColumn(name="company_id")
*/
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/Quote/NumericEntity.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
class NumericEntity
{
/**
* @var int
* @Id
* @Column(type="integer", name="`1:1`")
* @GeneratedValue(strategy="AUTO")
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/Models/Quote/Phone.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class Phone
public $number;

/**
* @var User
* @ManyToOne(targetEntity="User", inversedBy="phones")
* @JoinColumn(name="`user-id`", referencedColumnName="`user-id`")
*/
Expand Down
2 changes: 2 additions & 0 deletions tests/Doctrine/Tests/Models/Routing/RoutingLeg.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,14 @@ class RoutingLeg
public $id;

/**
* @var RoutingLocation
* @ManyToOne(targetEntity="RoutingLocation")
* @JoinColumn(name="from_id", referencedColumnName="id")
*/
public $fromLocation;

/**
* @var RoutingLocation
* @ManyToOne(targetEntity="RoutingLocation")
* @JoinColumn(name="to_id", referencedColumnName="id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ class RoutingRouteBooking
public $id;

/**
* @var RoutingRoute
* @ManyToOne(targetEntity="RoutingRoute", inversedBy="bookings")
* @JoinColumn(name="route_id", referencedColumnName="id")
*/
Expand Down
5 changes: 4 additions & 1 deletion tests/Doctrine/Tests/Models/Taxi/Car.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ class Car
*/
private $brand;

/** @Column(type="string", length=255); */
/**
* @var string
* @Column(type="string", length=255);
*/
private $model;

/** @OneToMany(targetEntity="Ride", mappedBy="car") */
Expand Down
5 changes: 4 additions & 1 deletion tests/Doctrine/Tests/Models/Taxi/Driver.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ class Driver
*/
private $id;

/** @Column(type="string", length=255); */
/**
* @var string
* @Column(type="string", length=255);
*/
private $name;

/** @OneToMany(targetEntity="Ride", mappedBy="driver") */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class OwningManyToOneEntity
public $id2;

/**
* @var InversedOneToManyEntity
* @ManyToOne(targetEntity="InversedOneToManyEntity", inversedBy="associatedEntities")
* @JoinColumn(name="associated_id", referencedColumnName="id1")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class OwningManyToOneExtraLazyEntity
public $id2;

/**
* @var InversedOneToManyExtraLazyEntity
* @ManyToOne(targetEntity="InversedOneToManyExtraLazyEntity", inversedBy="associatedEntities")
* @JoinColumn(name="associated_id", referencedColumnName="id1")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class OwningOneToOneEntity
public $id2;

/**
* @var InversedOneToOneEntity
* @OneToOne(targetEntity="InversedOneToOneEntity", inversedBy="associatedEntity")
* @JoinColumn(name="associated_id", referencedColumnName="id1")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,7 @@ class Phrase
public const CLASS_NAME = self::class;

/**
* @var int
* @Id
* @Column(type="integer", name="phrase_id")
* @GeneratedValue(strategy="AUTO")
Expand All @@ -340,6 +341,7 @@ class Phrase
private $phrase;

/**
* @var PhraseType
* @ManyToOne(targetEntity="PhraseType")
* @JoinColumn(name="phrase_type_id", referencedColumnName="phrase_type_id")
*/
Expand Down Expand Up @@ -399,6 +401,7 @@ class PhraseType
public const CLASS_NAME = self::class;

/**
* @var int
* @Id
* @Column(type="integer", name="phrase_type_id")
* @GeneratedValue(strategy="AUTO")
Expand Down Expand Up @@ -470,13 +473,15 @@ class Definition
public const CLASS_NAME = self::class;

/**
* @var int
* @Id
* @Column(type="integer", name="definition_id")
* @GeneratedValue(strategy="AUTO")
*/
private $id;

/**
* @var Phrase
* @ManyToOne(targetEntity="Phrase")
* @JoinColumn(name="definition_phrase_id", referencedColumnName="phrase_id")
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ class CTIRelated
private $id;

/**
* @var CTIParent
* @OneToOne(targetEntity="CTIParent")
* @JoinColumn(name="ctiparent_id", referencedColumnName="id")
*/
Expand Down
1 change: 1 addition & 0 deletions tests/Doctrine/Tests/ORM/Functional/DefaultValuesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ class DefaultValueAddress
public $street;

/**
* @var DefaultValueUser
* @OneToOne(targetEntity="DefaultValueUser")
* @JoinColumn(name="user_id", referencedColumnName="id")
*/
Expand Down
Loading

0 comments on commit ebae57e

Please sign in to comment.