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

[HttpFoundation] Standalone query string normalization#4711

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
fabpot merged 1 commit intosymfony:masterfromsimensen:normalize-querystring
Jul 2, 2012

Conversation

simensen
Copy link
Contributor

I wanted to leverage query string normalization in a test. I considered copying this code to my own library but I noticed that the only instance datagetQueryString needed to know from theRequest wasQUERY_STRING so I broke the rest out into a standalone static function.

*
* @return string|null A normalized query string for the Request
*
* @api
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

should be removed.

@simensen
Copy link
ContributorAuthor

I made the requested changes.

@fabpot
Copy link
Member

Can you squash your commits? Thanks.

@simensen
Copy link
ContributorAuthor

Sure, no problem. Hopefully I did it correctly.

fabpot added a commit that referenced this pull requestJul 2, 2012
Commits-------6296a24 Standalone query string normalizationDiscussion----------[HttpFoundation] Standalone query string normalizationI wanted to leverage query string normalization in a test. I considered copying this code to my own library but I noticed that the only instance data `getQueryString` needed to know from the `Request` was `QUERY_STRING` so I broke the rest out into a standalone static function.---------------------------------------------------------------------------by simensen at 2012-07-02T20:05:59ZI made the requested changes.---------------------------------------------------------------------------by fabpot at 2012-07-02T20:10:27ZCan you squash your commits? Thanks.---------------------------------------------------------------------------by simensen at 2012-07-02T20:16:52ZSure, no problem. Hopefully I did it correctly.
@fabpotfabpot merged commit6296a24 intosymfony:masterJul 2, 2012
@simensensimensen deleted the normalize-querystring branchJanuary 9, 2013 23:45
fabpot added a commit that referenced this pull requestSep 19, 2020
This PR was merged into the 5.2-dev branch.Discussion----------[VarDumper] Support for ReflectionAttribute| Q             | A| ------------- | ---| Branch?       | master| Bug fix?      | no| New feature?  | yes| Deprecations? | no| Tickets       | N/A| License       | MIT| Doc PR        | not neededVarDumper currently does not understand that certain reflection objects might have attributes attached to it. Dumping a `ReflectionAttribute` just yields `ReflectionAttribute {#4711}` which is not really helpful. This PR attempts to fix this.```ReflectionAttribute {#4711  name: "App\MyAttribute"  arguments: array:2 [    0 => "one"    "extra" => "hello"  ]}```While working on this, I noticed that class constants (which can be reflected on since PHP 7.1) are just dumped as plain values, so I've also added a caster for `ReflectionClasConstant` as bonus.The full output for the `LotsOfAttributes` fixture class that is included with is PR looks like this:<details>```^ ReflectionClass {#7  +name: "Symfony\Component\VarDumper\Tests\Fixtures\LotsOfAttributes"  modifiers: "final"  implements: []  constants: array:1 [    0 => ReflectionClassConstant {#20      +name: "SOME_CONSTANT"      +class: "Symfony\Component\VarDumper\Tests\Fixtures\LotsOfAttributes"      modifiers: "public"      value: "some value"      attributes: array:2 [        0 => ReflectionAttribute {#33          name: "Symfony\Component\VarDumper\Tests\Fixtures\RepeatableAttribute"          arguments: array:1 [            0 => "one"          ]        }        1 => ReflectionAttribute {#34          name: "Symfony\Component\VarDumper\Tests\Fixtures\RepeatableAttribute"          arguments: array:1 [            0 => "two"          ]        }      ]    }  ]  properties: array:1 [    "someProperty" => ReflectionProperty {#19      +name: "someProperty"      +class: "Symfony\Component\VarDumper\Tests\Fixtures\LotsOfAttributes"      modifiers: "private"      attributes: array:1 [        0 => ReflectionAttribute {#30          name: "Symfony\Component\VarDumper\Tests\Fixtures\MyAttribute"          arguments: array:2 [            0 => "one"            "extra" => "hello"          ]        }      ]    }  ]  methods: array:1 [    "someMethod" => ReflectionMethod {#21      +name: "someMethod"      +class: "Symfony\Component\VarDumper\Tests\Fixtures\LotsOfAttributes"      returnType: "void"      parameters: {        $someParameter: ReflectionParameter {#28          +name: "someParameter"          position: 0          attributes: array:1 [            0 => ReflectionAttribute {#42              name: "Symfony\Component\VarDumper\Tests\Fixtures\MyAttribute"              arguments: array:1 [                0 => "three"              ]            }          ]          typeHint: "string"        }      }      attributes: array:1 [        0 => ReflectionAttribute {#27          name: "Symfony\Component\VarDumper\Tests\Fixtures\MyAttribute"          arguments: array:1 [            0 => "two"          ]        }      ]      modifiers: "public"    }  ]  attributes: array:1 [    0 => ReflectionAttribute {#22      name: "Symfony\Component\VarDumper\Tests\Fixtures\MyAttribute"      arguments: []    }  ]  extra: {    file: "./src/Symfony/Component/VarDumper/Tests/Fixtures/LotsOfAttributes.php"    line: "15 to 28"    isUserDefined: true  }}```</details>Commits-------34dbf01 [VarDumper] Support for ReflectionAttribute.
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@simensen@fabpot

[8]ページ先頭

©2009-2025 Movatter.jp