Skip to content

Can't order "xmlns" attribute #886

@antoine-nedelec

Description

@antoine-nedelec
Q A
Bug report? yes

Steps required to reproduce the problem

  1. Add 2 attributes in a model, one of those attribute named xmlns, the other one doesn't matter the name
    /**
     * @var string
     * @SerializedName("xmlns")
     * @Groups({"xml_import"})
     * @XmlAttribute
     */
    private string $xmlns = 'string';
  1. Try to order those attributes with @AccessorOrder
  2. Check that any any case, xmlns is always at first place

Expected Result

  • Attribute should be in order specified in the @AccessorOrder (or in the order they are defined in the Model if no AccessorOrder).

Actual Result

  • xmlns is always rendered in first place.
  • Even though xmlns is a XmlNamespace, we should be able to position it where we want ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions