Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Removed useless parentheses in Assert annotations#10676

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
javiereguiluz merged 1 commit intosymfony:2.8fromthomasbisignani:patch-4
Nov 16, 2018
Merged
Show file tree
Hide file tree
Changes fromall 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
2 changes: 1 addition & 1 deletionbest_practices/forms.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -169,7 +169,7 @@ blank, add the following in the ``Post`` object::
class Post
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
public $title;
}
Expand Down
2 changes: 1 addition & 1 deletioncomponents/validator/resources.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -100,7 +100,7 @@ prefixed classes included in doc block comments (``/** ... */``). For example::
class User
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
protected $name;
}
Expand Down
8 changes: 4 additions & 4 deletionsdoctrine/registration_form.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -63,19 +63,19 @@ With some validation added, your class may look something like this::

/**
* @ORM\Column(type="string", length=255, unique=true)
* @Assert\NotBlank()
* @Assert\Email()
* @Assert\NotBlank
* @Assert\Email
*/
private $email;

/**
* @ORM\Column(type="string", length=255, unique=true)
* @Assert\NotBlank()
* @Assert\NotBlank
*/
private $username;

/**
* @Assert\NotBlank()
* @Assert\NotBlank
* @Assert\Length(max=4096)
*/
private $plainPassword;
Expand Down
4 changes: 2 additions & 2 deletionsform/embedded.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -25,7 +25,7 @@ of course, by creating the ``Category`` object::
class Category
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
public $name;
}
Expand All@@ -40,7 +40,7 @@ Next, add a new ``category`` property to the ``Task`` class::

/**
* @Assert\Type(type="AppBundle\Entity\Category")
* @Assert\Valid()
* @Assert\Valid
*/
protected $category;

Expand Down
4 changes: 2 additions & 2 deletionsforms.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -334,12 +334,12 @@ object.
class Task
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
public $task;
/**
* @Assert\NotBlank()
* @Assert\NotBlank
* @Assert\Type("\DateTime")
*/
protected $dueDate;
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Bic.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -37,7 +37,7 @@ will contain a Business Identifier Code (BIC).
class Transaction
{
/**
* @Assert\Bic()
* @Assert\Bic
*/
protected $businessIdentifierCode;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Blank.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -42,7 +42,7 @@ of an ``Author`` class were blank, you could do the following:
class Author
{
/**
* @Assert\Blank()
* @Assert\Blank
*/
protected $firstName;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Country.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -29,7 +29,7 @@ Basic Usage
class User
{
/**
* @Assert\Country()
* @Assert\Country
*/
protected $country;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Date.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -31,7 +31,7 @@ Basic Usage
class Author
{
/**
* @Assert\Date()
* @Assert\Date
*/
protected $birthday;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/DateTime.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -31,7 +31,7 @@ Basic Usage
class Author
{
/**
* @Assert\DateTime()
* @Assert\DateTime
*/
protected $createdAt;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/IsNull.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -36,7 +36,7 @@ of an ``Author`` class exactly equal to ``null``, you could do the following:
class Author
{
/**
* @Assert\IsNull()
* @Assert\IsNull
*/
protected $firstName;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Language.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -30,7 +30,7 @@ Basic Usage
class User
{
/**
* @Assert\Language()
* @Assert\Language
*/
protected $preferredLanguage;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Locale.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -34,7 +34,7 @@ Basic Usage
class User
{
/**
* @Assert\Locale()
* @Assert\Locale
*/
protected $locale;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/NotBlank.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -40,7 +40,7 @@ class were not blank, you could do the following:
class Author
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
protected $firstName;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/NotNull.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -34,7 +34,7 @@ class were not strictly equal to ``null``, you would:
class Author
{
/**
* @Assert\NotNull()
* @Assert\NotNull
*/
protected $firstName;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Time.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -34,7 +34,7 @@ of the day when the event starts:
class Event
{
/**
* @Assert\Time()
* @Assert\Time
*/
protected $startsAt;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/UniqueEntity.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -52,7 +52,7 @@ your user table:
* @var string $email
*
* @ORM\Column(name="email", type="string", length=255, unique=true)
* @Assert\Email()
* @Assert\Email
*/
protected $email;
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Url.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -32,7 +32,7 @@ Basic Usage
class Author
{
/**
* @Assert\Url()
* @Assert\Url
*/
protected $bioUrl;
}
Expand Down
2 changes: 1 addition & 1 deletionreference/constraints/Valid.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -57,7 +57,7 @@ stores an ``Address`` instance in the ``$address`` property::
class Address
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
protected $street;
Expand Down
4 changes: 2 additions & 2 deletionsvalidation.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -52,7 +52,7 @@ following:
class Author
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
public $name;
}
Expand DownExpand Up@@ -536,7 +536,7 @@ class to have at least 3 characters.
class Author
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
* @Assert\Length(min=3)
*/
private $firstName;
Expand Down
2 changes: 1 addition & 1 deletionvalidation/sequence_provider.rst
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -178,7 +178,7 @@ entity and a new constraint group called ``Premium``:
class User
{
/**
* @Assert\NotBlank()
* @Assert\NotBlank
*/
private $name;
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp