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

custom encoders interface signature#11439

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
OskarStark merged 1 commit intosymfony:4.2fromPandaaAgency:patch-1
May 24, 2019

Conversation

@PandaaAgency
Copy link
Contributor

@PandaaAgencyPandaaAgency commentedApr 15, 2019
edited by OskarStark
Loading

Fixes the documentation about encoders that was wrong.
UsingSymfony\Component\Serializer\Encoder\EncoderInterface no$context parameter is passed tosupportsEncoding method. You have to use the ContextAware version of it.

Fixes the documentation about encoders that was wrong.Using `Symfony\Component\Serializer\Encoder\EncoderInterface` no `$context` parameter is passed to `supportsEncoding` method. YOu have to use the ContextAware version of it.
..tip::

If you need access to ``$context`` in your ``supportsDecoding`` or ``supportsEncoding`` method, make sure
to implements ``Symfony\Component\Serializer\Encoder\ContextAwareEncoderInterface`` or ``Symfony\Component\Serializer\Encoder\ContextAwareEncoderInterface`` interface
Copy link
Contributor

@OskarStarkOskarStarkApr 15, 2019
edited
Loading

Choose a reason for hiding this comment

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

Suggested change
toimplements ``Symfony\Component\Serializer\Encoder\ContextAwareEncoderInterface`` or ``Symfony\Component\Serializer\Encoder\ContextAwareEncoderInterface``interface
toimplement ``Symfony\Component\Serializer\Encoder\ContextAwareDecoderInterface`` or ``Symfony\Component\Serializer\Encoder\ContextAwareEncoderInterface``accordingly.

Why the same interface twice?

and a . (Dot) is missing at the end

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah I found out by myself,Decoder andEncoder....

@OskarStarkOskarStark added this to the4.2 milestoneMay 24, 2019
@OskarStark
Copy link
Contributor

OskarStark commentedMay 24, 2019
edited
Loading

... and one more bug fixed, thank you Florian and congratulations on your first contribution to the Symfony-Docs 🎉 ❗️

@OskarStarkOskarStark merged commit754a62b intosymfony:4.2May 24, 2019
OskarStark added a commit that referenced this pull requestMay 24, 2019
This PR was merged into the 4.2 branch.Discussion----------custom encoders interface signatureFixes the documentation about encoders that was wrong.Using `Symfony\Component\Serializer\Encoder\EncoderInterface` no `$context` parameter is passed to `supportsEncoding` method. You have to use the ContextAware version of it.<!--If your pull request fixes a BUG, use the oldest maintained branch that containsthe bug (seehttps://symfony.com/roadmap for the list of maintained branches).If your pull request documents a NEW FEATURE, use the same Symfony branch wherethe feature was introduced (and `master` for features of unreleased versions).-->Commits-------754a62b custom encoders interface signature
OskarStark added a commit that referenced this pull requestMay 24, 2019
OskarStark added a commit that referenced this pull requestMay 24, 2019
* 4.2:  Tweaks. refs#11439  custom encoders interface signature
OskarStark added a commit that referenced this pull requestMay 24, 2019
* 4.3:  Tweaks. refs#11439  custom encoders interface signature
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@OskarStarkOskarStarkOskarStark approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

4.2

Development

Successfully merging this pull request may close these issues.

4 participants

@PandaaAgency@OskarStark@javiereguiluz@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp