8000 [Serializer] split off an EncoderInterface and NormalizerInterface from SerializerInte by lsmith77 · Pull Request #2530 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[Serializer] split off an EncoderInterface and NormalizerInterface from SerializerInte #2530

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

Merged
merged 16 commits into from
Dec 14, 2011
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
updated serializer tests to use the new interfaces
  • Loading branch information
lsmith77 committed Dec 11, 2011
commit 067242d003111441ba2b9a16a1caaf01d48c71b1
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,20 @@
namespace Symfony\Tests\Component\Serializer\Fixtures;

use Symfony\Component\Serializer\Normalizer\NormalizableInterface;
use Symfony\Component\Serializer\SerializerInterface;
use Symfony\Component\Serializer\Normalizer\NormalizerInterface;
use Symfony\Component\Serializer\Normalizer\DenormalizerInterface;

class NormalizableTraversableDummy extends TraversableDummy implements NormalizableInterface
{
public function normalize(SerializerInterface $serializer, $format = null)
public function normalize(NormalizerInterface $normalizer, $format = null)
{
return array(
'foo' => 'normalizedFoo',
'bar' => 'normalizedBar',
);
}

public function denormalize(SerializerInterface $serializer, $data, $format = null)
public function denormalize(DenormalizerInterface $denormalizer, $data, $format = null)
{
return array(
'foo' => 'denormalizedFoo',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@
namespace Symfony\Tests\Component\Serializer\Fixtures;

use Symfony\Component\Serializer\Normalizer\NormalizableInterface;
use Symfony\Component\Serializer\Normalizer\DenormalizableInterface;
use Symfony\Component\Serializer\Normalizer\NormalizerInterface;
use Symfony\Component\Serializer\Normalizer\DenormalizerInterface;

class ScalarDummy implements NormalizableInterface
class ScalarDummy implements NormalizableInterface, DenormalizableInterface
{
public $foo;
public $xmlFoo;
Expand Down
0