Projet

Général

Profil

Development #50

Add a strict mode for lasso_node_init_from_xml

Ajouté par Benjamin Dauvergne il y a presque 14 ans. Mis à jour il y a presque 12 ans.

Statut:
Nouveau
Priorité:
Normal
Assigné à:
-
Catégorie:
XML Framework
Version cible:
Début:
22 mai 2010
Echéance:
% réalisé:

0%

Temps estimé:
15:00 h
Patch proposed:
Planning:

Description

We already have some form of schema through the XmlSnippet structures. I think we could add more strict checking with some more flags and checking.

First we could check strict ordering since XSchema suppose it. That is we would match the sub-elements in-order unless specified otherwise (they are in an <xs:choice/>). As the XmlSnippet cannot be nested, the flag would be put on the sub-elements contained in the choice and would mean "don't care about my order", SNIPPET_UNORDERED wouldbe a good name.

Second we could check cardinality. I think there is only three cardinalities used in SAML standards:
  • needed (1)
  • optional (0 or 1)
  • optional-free (0 or more)
    that could be mapped to three new flags: SNIPPET_NEEDED, SNIPPET_OPTIONAL and SNIPPET_OPTIONAL_FREE.

We could even implement a script to check that all SNIPPET_OPTIONAL_FREE points to properly declared GList fields.

Historique

#1

Mis à jour par Benjamin Dauvergne il y a presque 14 ans

  • Catégorie mis à XML Framework
#2

Mis à jour par Benjamin Dauvergne il y a presque 12 ans

  • Assigné à Benjamin Dauvergne supprimé

Formats disponibles : Atom PDF