@@ -76,6 +76,9 @@ SedNamespaces::initSedNamespace()
7676 case 4 :
7777 mNamespaces ->add (SEDML_XMLNS_L1V4);
7878 break ;
79+ case 5 :
80+ mNamespaces ->add (SEDML_XMLNS_L1V5);
81+ break ;
7982 }
8083 break ;
8184 }
@@ -129,6 +132,7 @@ SedNamespaces::getSupportedNamespaces()
129132 result->add (new SedNamespaces (1 ,2 ));
130133 result->add (new SedNamespaces (1 ,3 ));
131134 result->add (new SedNamespaces (1 ,4 ));
135+ result->add (new SedNamespaces (1 ,5 ));
132136 return result;
133137}
134138
@@ -201,6 +205,9 @@ SedNamespaces::getSedNamespaceURI(unsigned int level,
201205 case 4 :
202206 uri = SEDML_XMLNS_L1V4;
203207 break ;
208+ case 5 :
209+ uri = SEDML_XMLNS_L1V5;
210+ break ;
204211 }
205212 break ;
206213 }
@@ -358,6 +365,12 @@ SedNamespaces::isValidCombination()
358365 declaredURI.assign (SEDML_XMLNS_L1V4);
359366 }
360367
368+ if (xmlns->hasURI (SEDML_XMLNS_L1V5))
369+ {
370+ ++numNS;
371+ declaredURI.assign (SEDML_XMLNS_L1V5);
372+ }
373+
361374 // checks if the SED-ML Namespace is explicitly defined.
362375 for (int i=0 ; i < xmlns->getLength (); i++)
363376 {
@@ -420,6 +433,17 @@ SedNamespaces::isValidCombination()
420433 }
421434 }
422435 break ;
436+ case 5 :
437+ // the namespaces contains the sedml namespaces
438+ // check it is the correct ns for the level/version
439+ if (sedmlDeclared)
440+ {
441+ if (declaredURI != string (SEDML_XMLNS_L1V5))
442+ {
443+ valid = false ;
444+ }
445+ }
446+ break ;
423447 default :
424448 valid = false ;
425449 break ;
0 commit comments