Skip to content
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

Add constants for the formats #1105

Closed
wants to merge 2 commits into from
Closed

Add constants for the formats #1105

wants to merge 2 commits into from

Conversation

kiironoaki
Copy link
Contributor

Q A
Bug fix? no
New feature? no
Doc updated yes
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #1079
License MIT

@kiironoaki kiironoaki changed the title 1079 format constants Format constants Jul 7, 2019
@kiironoaki kiironoaki changed the title Format constants Add constants for the formats Jul 7, 2019
public const FORMAT_JSON = 'json';
public const FORMAT_XML = 'xml';

public const FORMATS_SUPPORTED = [
Copy link
Collaborator

Choose a reason for hiding this comment

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

not sure if this is a good idea.
Having this constants in the serializer interface does not allow to add formats (visitors) without changing this interface.

This makes useless the idea of being able to add your own visitors.

Copy link
Collaborator

@goetas goetas left a comment

Choose a reason for hiding this comment

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

Hi, thanks for the PR, but overall I'm not sure it is a good idea.

Change my mind?

@goetas goetas added the RFC label Aug 18, 2019
@goetas
Copy link
Collaborator

goetas commented Aug 18, 2019

AS per motivations in #1105 (comment), closing this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants