|
From: <sar...@us...> - 2013-07-26 15:08:08
|
Revision: 18269
http://sourceforge.net/p/sbml/code/18269
Author: sarahkeating
Date: 2013-07-26 15:08:02 +0000 (Fri, 26 Jul 2013)
Log Message:
-----------
adding validation to layout
Modified Paths:
--------------
trunk/libsbml/src/sbml/packages/layout/sbml/GraphicalObject.cpp
trunk/libsbml/src/sbml/packages/layout/sbml/ReferenceGlyph.cpp
trunk/libsbml/src/sbml/packages/layout/sbml/SpeciesReferenceGlyph.cpp
trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLError.h
trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLErrorTable.h
Added Paths:
-----------
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-pass-00-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-02.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-pass-00-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020905-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020910-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021002-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021002-pass-00-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021004-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021004-fail-01-02.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021004-pass-00-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021005-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021007-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021010-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021012-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021102-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021102-pass-00-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021104-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021104-fail-01-02.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021104-fail-01-03.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021104-pass-00-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021105-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021107-fail-01-01.xml
trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021110-fail-01-01.xml
Modified: trunk/libsbml/src/sbml/packages/layout/sbml/GraphicalObject.cpp
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/sbml/GraphicalObject.cpp 2013-07-26 11:57:57 UTC (rev 18268)
+++ trunk/libsbml/src/sbml/packages/layout/sbml/GraphicalObject.cpp 2013-07-26 15:08:02 UTC (rev 18269)
@@ -595,11 +595,17 @@
getPackageVersion(), sbmlLevel, sbmlVersion);
break;
case SBML_LAYOUT_SPECIESREFERENCEGLYPH:
+ getErrorLog()->logPackageError("layout", LayoutSRGAllowedAttributes,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
+ break;
case SBML_LAYOUT_TEXTGLYPH:
getErrorLog()->logPackageError("layout", LayoutTGAllowedAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion);
break;
case SBML_LAYOUT_REFERENCEGLYPH:
+ getErrorLog()->logPackageError("layout", LayoutREFGAllowedAttributes,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
+ break;
case SBML_LAYOUT_GENERALGLYPH:
getErrorLog()->logPackageError("layout", LayoutGGAllowedAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion);
@@ -633,11 +639,17 @@
getPackageVersion(), sbmlLevel, sbmlVersion);
break;
case SBML_LAYOUT_SPECIESREFERENCEGLYPH:
+ getErrorLog()->logPackageError("layout", LayoutSRGMetaIdRefMustBeIDREF,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
+ break;
case SBML_LAYOUT_TEXTGLYPH:
getErrorLog()->logPackageError("layout", LayoutTGMetaIdRefMustBeIDREF,
getPackageVersion(), sbmlLevel, sbmlVersion);
break;
case SBML_LAYOUT_REFERENCEGLYPH:
+ getErrorLog()->logPackageError("layout", LayoutREFGMetaIdRefMustBeIDREF,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
+ break;
case SBML_LAYOUT_GENERALGLYPH:
getErrorLog()->logPackageError("layout", LayoutGGMetaIdRefMustBeIDREF,
getPackageVersion(), sbmlLevel, sbmlVersion);
Modified: trunk/libsbml/src/sbml/packages/layout/sbml/ReferenceGlyph.cpp
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/sbml/ReferenceGlyph.cpp 2013-07-26 11:57:57 UTC (rev 18268)
+++ trunk/libsbml/src/sbml/packages/layout/sbml/ReferenceGlyph.cpp 2013-07-26 15:08:02 UTC (rev 18269)
@@ -535,7 +535,7 @@
const std::string details =
getErrorLog()->getError(n)->getMessage();
getErrorLog()->remove(UnknownPackageAttribute);
- getErrorLog()->logPackageError("layout", LayoutUnknownError,
+ getErrorLog()->logPackageError("layout", LayoutREFGAllowedAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion, details);
}
else if (getErrorLog()->getError(n)->getErrorId() == UnknownCoreAttribute)
@@ -543,7 +543,8 @@
const std::string details =
getErrorLog()->getError(n)->getMessage();
getErrorLog()->remove(UnknownCoreAttribute);
- getErrorLog()->logPackageError("layout", LayoutUnknownError,
+ getErrorLog()->logPackageError("layout",
+ LayoutREFGAllowedCoreAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion, details);
}
}
@@ -568,13 +569,14 @@
}
else if (SyntaxChecker::isValidSBMLSId(mGlyph) == false)
{
- logError(InvalidIdSyntax);
+ getErrorLog()->logPackageError("layout", LayoutREFGGlyphSyntax,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
}
}
else
{
std::string message = "Layout attribute 'glyph' is missing.";
- getErrorLog()->logPackageError("layout", LayoutUnknownError,
+ getErrorLog()->logPackageError("layout", LayoutREFGAllowedAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion, message);
}
}
@@ -594,7 +596,8 @@
}
else if (SyntaxChecker::isValidSBMLSId(mReference) == false)
{
- logError(InvalidIdSyntax);
+ getErrorLog()->logPackageError("layout", LayoutREFGReferenceSyntax,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
}
}
Modified: trunk/libsbml/src/sbml/packages/layout/sbml/SpeciesReferenceGlyph.cpp
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/sbml/SpeciesReferenceGlyph.cpp 2013-07-26 11:57:57 UTC (rev 18268)
+++ trunk/libsbml/src/sbml/packages/layout/sbml/SpeciesReferenceGlyph.cpp 2013-07-26 15:08:02 UTC (rev 18269)
@@ -582,7 +582,7 @@
const std::string details =
getErrorLog()->getError(n)->getMessage();
getErrorLog()->remove(UnknownPackageAttribute);
- getErrorLog()->logPackageError("layout", LayoutUnknownError,
+ getErrorLog()->logPackageError("layout", LayoutSRGAllowedAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion, details);
}
else if (getErrorLog()->getError(n)->getErrorId() == UnknownCoreAttribute)
@@ -590,7 +590,7 @@
const std::string details =
getErrorLog()->getError(n)->getMessage();
getErrorLog()->remove(UnknownCoreAttribute);
- getErrorLog()->logPackageError("layout", LayoutUnknownError,
+ getErrorLog()->logPackageError("layout", LayoutSRGAllowedCoreAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion, details);
}
}
@@ -616,13 +616,14 @@
}
else if (SyntaxChecker::isValidSBMLSId(mSpeciesGlyph) == false)
{
- logError(InvalidIdSyntax);
+ getErrorLog()->logPackageError("layout", LayoutSRGSpeciesGlyphSyntax,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
}
}
else
{
std::string message = "Layout attribute 'speciesGlyph' is missing.";
- getErrorLog()->logPackageError("layout", LayoutUnknownError,
+ getErrorLog()->logPackageError("layout", LayoutSRGAllowedAttributes,
getPackageVersion(), sbmlLevel, sbmlVersion, message);
}
}
@@ -638,11 +639,14 @@
if (mSpeciesReference.empty() == true)
{
- logEmptyString(mSpeciesReference, getLevel(), getVersion(), "<SpeciesReferenceGlyph>");
+ logEmptyString(mSpeciesReference, getLevel(), getVersion(),
+ "<SpeciesReferenceGlyph>");
}
else if (SyntaxChecker::isValidSBMLSId(mSpeciesReference) == false)
{
- logError(InvalidIdSyntax);
+
+ getErrorLog()->logPackageError("layout", LayoutSRGSpeciesReferenceSyntax,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
}
}
@@ -663,11 +667,22 @@
else
{
this->setRole(role);
+
+ if (this->getRole() == SPECIES_ROLE_UNDEFINED && getErrorLog() != NULL)
+ {
+ getErrorLog()->logPackageError("layout", LayoutSRGRoleSyntax,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
+ }
}
}
else
{
this->setRole(SPECIES_ROLE_UNDEFINED);
+ if (getErrorLog() != NULL)
+ {
+ getErrorLog()->logPackageError("layout", LayoutSRGRoleSyntax,
+ getPackageVersion(), sbmlLevel, sbmlVersion);
+ }
}
Modified: trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLError.h
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLError.h 2013-07-26 11:57:57 UTC (rev 18268)
+++ trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLError.h 2013-07-26 15:08:02 UTC (rev 18269)
@@ -105,8 +105,6 @@
, LayoutRGNoDuplicateReferences = 6020709
, LayoutLOSpeciesRefGlyphAllowedElements = 6020710
, LayoutLOSpeciesRefGlyphAllowedAttribs = 6020711
-
-
, LayoutGGAllowedCoreElements = 6020801
, LayoutGGAllowedCoreAttributes = 6020802
, LayoutGGAllowedElements = 6020803
@@ -120,7 +118,6 @@
, LayoutLOReferenceGlyphAllowedAttribs = 6020811
, LayoutLOSubGlyphAllowedElements = 6020812
, LayoutLOSubGlyphAllowedAttribs = 6020813
-
, LayoutTGAllowedCoreElements = 6020901
, LayoutTGAllowedCoreAttributes = 6020902
, LayoutTGAllowedElements = 6020903
@@ -134,6 +131,34 @@
, LayoutTGGraphicalObjectMustRefObject = 6020911
, LayoutTGTextMustBeString = 6020912
+ , LayoutSRGAllowedCoreElements = 6021001
+ , LayoutSRGAllowedCoreAttributes = 6021002
+ , LayoutSRGAllowedElements = 6021003
+ , LayoutSRGAllowedAttributes = 6021004
+ , LayoutSRGMetaIdRefMustBeIDREF = 6021005
+ , LayoutSRGMetaIdRefMustReferenceObject = 6021006
+ , LayoutSRGSpeciesReferenceSyntax = 6021007
+ , LayoutSRGSpeciesRefMustRefObject = 6021008
+ , LayoutSRGNoDuplicateReferences = 6021009
+ , LayoutSRGSpeciesGlyphSyntax = 6021010
+ , LayoutSRGSpeciesGlyphMustRefObject = 6021011
+ , LayoutSRGRoleSyntax = 6021012
+ , LayoutSRGRoleMustBeSRGRoleValue = 6021013
+
+ , LayoutREFGAllowedCoreElements = 6021101
+ , LayoutREFGAllowedCoreAttributes = 6021102
+ , LayoutREFGAllowedElements = 6021103
+ , LayoutREFGAllowedAttributes = 6021104
+ , LayoutREFGMetaIdRefMustBeIDREF = 6021105
+ , LayoutREFGMetaIdRefMustReferenceObject = 6021106
+ , LayoutREFGReferenceSyntax = 6021107
+ , LayoutREFGReferenceMustRefObject = 6021108
+ , LayoutREFGNoDuplicateReferences = 6021109
+ , LayoutREFGGlyphSyntax = 6021110
+ , LayoutREFGGlyphMustRefObject = 6021111
+ , LayoutREFGRoleSyntax = 6021112
+
+
} LayoutSBMLErrorCode_t;
END_C_DECLS
Modified: trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLErrorTable.h
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLErrorTable.h 2013-07-26 11:57:57 UTC (rev 18268)
+++ trunk/libsbml/src/sbml/packages/layout/validator/LayoutSBMLErrorTable.h 2013-07-26 15:08:02 UTC (rev 18269)
@@ -446,7 +446,7 @@
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
"A <graphicalObject> object must have the required attribute "
- "'layout:id and may have the optional attribute 'layout:metaidRef'. "
+ "'layout:id' and may have the optional attribute 'layout:metaidRef'. "
"No other attributes from the Layout namespace "
"are permitted on a <graphicalObject>. ",
{ "L3V1 Layout V1 Section 3.7"
@@ -528,7 +528,7 @@
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
"A <compartmentGlyph> object must have the required attribute "
- "'layout:id and may have the optional attributes 'layout:metaidRef' "
+ "'layout:id' and may have the optional attributes 'layout:metaidRef' "
"or 'layout:compartment'. "
"No other attributes from the Layout namespace "
"are permitted on a <compartmentGlyph>. ",
@@ -645,7 +645,7 @@
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
"A <speciesGlyph> object must have the required attribute "
- "'layout:id and may have the optional attributes 'layout:metaidRef' "
+ "'layout:id' and may have the optional attributes 'layout:metaidRef' "
"or 'layout:species'. "
"No other attributes from the Layout namespace "
"are permitted on a <speciesGlyph>. ",
@@ -752,7 +752,7 @@
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
"A <reactionGlyph> object must have the required attribute "
- "'layout:id and may have the optional attributes 'layout:metaidRef' "
+ "'layout:id' and may have the optional attributes 'layout:metaidRef' "
"or 'layout:reaction'. "
"No other attributes from the Layout namespace "
"are permitted on a <reactionGlyph>. ",
@@ -886,7 +886,7 @@
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
"A <generalGlyph> object must have the required attribute "
- "'layout:id and may have the optional attributes 'layout:metaidRef' "
+ "'layout:id' and may have the optional attributes 'layout:metaidRef' "
"or 'layout:reference'. "
"No other attributes from the Layout namespace "
"are permitted on a <generalGlyph>. ",
@@ -1032,7 +1032,7 @@
"Layout elements allowed on <textGlyph>.",
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
- "A ><textGlyph> must contain exactly one <boundingBox> object. "
+ "A <textGlyph> must contain exactly one <boundingBox> object. "
"No other elements from "
"the Layout namespace are permitted on a <textGlyph>. ",
{ "L3V1 Layout V1 Section 3.12"
@@ -1045,7 +1045,7 @@
LIBSBML_CAT_GENERAL_CONSISTENCY,
LIBSBML_SEV_ERROR,
"A <textGlyph> object must have the required attribute "
- "'layout:id and may have the optional attributes 'layout:metaidRef', "
+ "'layout:id' and may have the optional attributes 'layout:metaidRef', "
"'layout:graphicalObject', 'layout:text' and 'layout:originOfText'. "
"No other attributes from the Layout namespace "
"are permitted on a <textGlyph>. ",
@@ -1143,10 +1143,311 @@
}
},
+ // 6021001
+ { LayoutSRGAllowedCoreElements,
+ "Core elements allowed on <speciesReferenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <speciesReferenceGlyph> object may have the optional SBML Level 3 Core "
+ "subobjects for notes and annotations. No other elements from the SBML "
+ "Level 3 Core namespace are permitted on a <speciesReferenceGlyph>. ",
+ { "L3V1 Core Section 3.2"
+ }
+ },
+
+ // 6021002
+ { LayoutSRGAllowedCoreAttributes,
+ "Core attributes allowed on <speciesReferenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <speciesReferenceGlyph> object may have the optional SBML Level 3 Core "
+ "attributes 'metaid' and 'sboTerm'. No other attributes from the SBML "
+ "Level 3 Core namespace are permitted on a <speciesReferenceGlyph>. ",
+ { "L3V1 Core Section 3.2"
+ }
+ },
+
+ // 6021003
+ { LayoutSRGAllowedElements,
+ "Layout elements allowed on <speciesReferenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <speciesReferenceGlyph> may have at most one instance of a "
+ "<boundingBox> and <curve> object. "
+ "No other elements from "
+ "the Layout namespace are permitted on a <speciesReferenceGlyph>. ",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+
+ // 6021004
+ { LayoutSRGAllowedAttributes,
+ "Layout attributes allowed on <speciesReferenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <speciesReferenceGlyph> object must have the required attribute "
+ "'layout:id' and may have the optional attributes 'layout:metaidRef', "
+ "'layout:speciesReference' and 'layout:role'. "
+ "No other attributes from the Layout namespace "
+ "are permitted on a <speciesReferenceGlyph>. ",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+ // 6021005
+ { LayoutSRGMetaIdRefMustBeIDREF,
+ "Layout 'metIdRef' must be IDREF.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:metaidRef' of a <speciesReferenceGlyph> "
+ "must be of the data type 'IDREF'.",
+ { "L3V1 Layout V1 Section 3.7"
+ }
+ },
+ // 6021006
+ { LayoutSRGMetaIdRefMustReferenceObject,
+ "Layout 'metIdRef' must reference existing object.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of a 'layout:metaidRef' attribute of a <speciesReferenceGlyph> "
+ "must be of the 'metaid' of an existing element in the <model>.",
+ { "L3V1 Layout V1 Section 3.7"
+ }
+ },
+ // 6021007
+ { LayoutSRGSpeciesReferenceSyntax,
+ "SpeciesReferenceGlyph 'speciesReference' must have SIdRef syntax.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:speciesReference' of a <speciesReferenceGlyph> "
+ "must be the data type 'SIdRef'.",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+ // 6021008
+ { LayoutSRGSpeciesRefMustRefObject,
+ "SpeciesReferenceGlyph 'speciesReference' must reference existing element.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of the 'layout:speciesReference' attribute of a "
+ "<speciesReferenceGlyph> "
+ "must be of the 'id' of an existing <speciesReference> in the <model>.",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+
+ // 6021009
+ { LayoutSRGNoDuplicateReferences,
+ "SpeciesReferenceGlyph cannot reference two objects.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "If both attributes 'layout:speciesReference' and 'layout:metaidRef' "
+ "are specified on a <speciesReferenceGlyph> they have to reference "
+ "the same <speciesReference> in the <model>.",
+ { "L3V1 Layout V1 Section 3.12"
+ }
+ },
+
+ // 6021010
+ { LayoutSRGSpeciesGlyphSyntax,
+ "SpeciesReferenceGlyph 'speciesGlyph' must have SIdRef syntax.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:speciesGlyph' of a <speciesReferenceGlyph> "
+ "must be the data type 'SIdRef'.",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+
+ // 6021011
+ { LayoutSRGSpeciesGlyphMustRefObject,
+ "SpeciesReferenceGlyph 'speciesGlyph' must reference existing element.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of the 'layout:speciesGlyph' attribute of a "
+ "<speciesReferenceGlyph> "
+ "must be of the 'id' of an existing <speciesGlyph> "
+ "element in the <layout>.",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+
+ // 6021012
+ { LayoutSRGRoleSyntax,
+ "SpeciesReferenceGlyph 'role' must be string.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:role' of a <speciesReferenceGlyph> "
+ "must be the data type 'SpeciesReferenceRole'.",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+
+ // 6021013
+ { LayoutSRGRoleMustBeSRGRoleValue,
+ "SpeciesReferenceGlyph 'role' must be from enumeration.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of a 'layout:role' of a <speciesReferenceGlyph> "
+ "must be one of: substrate, product, sidesubstrate, sideproduct, "
+ "modifier, activator, inhibitor or undefined.",
+ { "L3V1 Layout V1 Section 3.10.1"
+ }
+ },
+
+ // 6021101
+ { LayoutREFGAllowedCoreElements,
+ "Core elements allowed on <referenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <referenceGlyph> object may have the optional SBML Level 3 Core "
+ "subobjects for notes and annotations. No other elements from the SBML "
+ "Level 3 Core namespace are permitted on a <referenceGlyph>. ",
+ { "L3V1 Core Section 3.2"
+ }
+ },
+
+ // 6021102
+ { LayoutREFGAllowedCoreAttributes,
+ "Core attributes allowed on <referenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <referenceGlyph> object may have the optional SBML Level 3 Core "
+ "attributes 'metaid' and 'sboTerm'. No other attributes from the SBML "
+ "Level 3 Core namespace are permitted on a <referenceGlyph>. ",
+ { "L3V1 Core Section 3.2"
+ }
+ },
+
+ // 6021103
+ { LayoutREFGAllowedElements,
+ "Layout elements allowed on <referenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "There may be at most one instance of a <boundingBox> and "
+ "<curve> object on a <referenceGlyph>. "
+ "No other elements from "
+ "the Layout namespace are permitted on a <referenceGlyph>. ",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+ // 6021104
+ { LayoutREFGAllowedAttributes,
+ "Layout attributes allowed on <referenceGlyph>.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "A <referenceGlyph> object must have the required attributes "
+ "'layout:id' and 'layout:glyph' and may have the optional attributes "
+ "'layout:metaidRef', "
+ "'layout:reference' and 'layout:role'. "
+ "No other attributes from the Layout namespace "
+ "are permitted on a <referenceGlyph>. ",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+ // 6021105
+ { LayoutREFGMetaIdRefMustBeIDREF,
+ "Layout 'metIdRef' must be IDREF.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:metaidRef' of a <referenceGlyph> "
+ "must be of the data type 'IDREF'.",
+ { "L3V1 Layout V1 Section 3.7"
+ }
+ },
+
+ // 6021106
+ { LayoutREFGMetaIdRefMustReferenceObject,
+ "Layout 'metIdRef' must reference existing object.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of a 'layout:metaidRef' attribute of a <referenceGlyph> "
+ "must be of the 'metaid' of an existing element in the <model>.",
+ { "L3V1 Layout V1 Section 3.7"
+ }
+ },
+
+ // 6021107
+ { LayoutREFGReferenceSyntax,
+ "ReferenceGlyph 'reference' must have SIdRef syntax.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:reference' of a <referenceGlyph> "
+ "must be the data type 'SIdRef'.",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+ // 6021108
+ { LayoutREFGReferenceMustRefObject,
+ "ReferenceGlyph 'reference' must reference existing element.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of the 'layout:reference' attribute of a "
+ "<referenceGlyph> "
+ "must be of the 'id' of an existing element in the <model>.",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+ // 6021109
+ { LayoutREFGNoDuplicateReferences,
+ "ReferenceGlyph cannot reference two objects.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "If both attributes 'layout:reference' and 'layout:metaidRef' "
+ "are specified on a <referenceGlyph> they have to reference "
+ "the same element in the <model>.",
+ { "L3V1 Layout V1 Section 3.12"
+ }
+ },
+
+ // 6021110
+ { LayoutREFGGlyphSyntax,
+ "ReferenceGlyph 'glyph' must have SIdRef syntax.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:glyph' of a <referenceGlyph> "
+ "must be the data type 'SIdRef'.",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+ // 6021111
+ { LayoutREFGGlyphMustRefObject,
+ "ReferenceGlyph 'glyph' must reference existing element.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The value of the 'layout:glyph' attribute of a "
+ "<referenceGlyph> "
+ "must be of the 'id' of an existing <graphicalObject> (or derived) "
+ "element in the <layout>.",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+ // 6021112
+ { LayoutREFGRoleSyntax,
+ "ReferenceGlyph 'role' must be string.",
+ LIBSBML_CAT_GENERAL_CONSISTENCY,
+ LIBSBML_SEV_ERROR,
+ "The attribute 'layout:role' of a <referenceGlyph> "
+ "must be the data type 'string'.",
+ { "L3V1 Layout V1 Section 3.11.1"
+ }
+ },
+
+
+
+
+
+
+
};
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-fail-01-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-fail-01-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-fail-01-01.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph layout:id="TextGlyph_Glucose"
+ layout:originOfText="Glucose"
+ layout:graphicalObject="SpeciesGlyph_Glucose"
+ metaid="mid" sboTerm="SBO:0000001" species="Glucose">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-pass-00-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-pass-00-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020902-pass-00-01.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph layout:id="TextGlyph_Glucose"
+ layout:originOfText="Glucose"
+ layout:graphicalObject="SpeciesGlyph_Glucose"
+ metaid="mid" sboTerm="SBO:0000001">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-01.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose" metaid="_SG1">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph
+ layout:originOfText="Glucose"
+ layout:graphicalObject="SpeciesGlyph_Glucose"
+ layout:metaidRef="_SG1" layout:text="SBO:0000001">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-02.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-02.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-fail-01-02.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose" metaid="_SG1">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph layout:id="TextGlyph_Glucose"
+ layout:originOfText="Glucose"
+ layout:graphicalObject="SpeciesGlyph_Glucose"
+ layout:metaidRef="_SG1" layout:text="SBO:0000001" layout:species="Glucose">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-pass-00-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-pass-00-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020904-pass-00-01.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose" metaid="_SG1">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph layout:id="TextGlyph_Glucose"
+ layout:originOfText="Glucose"
+ layout:graphicalObject="SpeciesGlyph_Glucose"
+ layout:metaidRef="_SG1" layout:text="SBO:0000001">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020905-fail-01-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020905-fail-01-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020905-fail-01-01.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose" metaid="_SG1">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph layout:id="TextGlyph_Glucose"
+ layout:originOfText="Glucose"
+ layout:graphicalObject="SpeciesGlyph_Glucose"
+ layout:metaidRef="1_SG1" layout:text="SBO:0000001">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020910-fail-01-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020910-fail-01-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6020910-fail-01-01.xml 2013-07-26 15:08:02 UTC (rev 18269)
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<sbml xmlns="http://www.sbml.org/sbml/level3/version1/core"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1"
+ level="3" version="1" layout:required="false" >
+ <model id="TestModel_with_modifiers" timeUnits="time">
+
+ <listOfCompartments>
+ <compartment id="Yeast" spatialDimensions="3" units="volume" constant="true"/>
+ </listOfCompartments>
+ <listOfSpecies>
+ <species id="Glucose" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="G6P" name="Glucose-6-phosphate" compartment="Yeast"
+ substanceUnits="substance" hasOnlySubstanceUnits="false"
+ boundaryCondition="false" constant="false"/>
+ <species id="ATP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="ADP" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ <species id="Pi" compartment="Yeast" substanceUnits="substance"
+ hasOnlySubstanceUnits="false" boundaryCondition="false" constant="false"/>
+ </listOfSpecies>
+ <listOfReactions>
+ <reaction id="Hexokinase" reversible="false" fast="false">
+ <listOfReactants>
+ <speciesReference id="SpeciesReference_Glucose" species="Glucose"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ATP" species="ATP"
+ stoichiometry="1" constant="true"/>
+ </listOfReactants>
+ <listOfProducts>
+ <speciesReference id="SpeciesReference_G6P" species="G6P"
+ stoichiometry="1" constant="true"/>
+ <speciesReference id="SpeciesReference_ADP" species="ADP"
+ stoichiometry="1" constant="true"/>
+ </listOfProducts>
+ <listOfModifiers>
+ <modifierSpeciesReference id="ModifierSpeciesReference_G6P" species="G6P"/>
+ <modifierSpeciesReference id="ModifierSpeciesReference_Pi" species="Pi"/>
+ </listOfModifiers>
+ </reaction>
+ </listOfReactions>
+ <layout:listOfLayouts xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:layout="http://www.sbml.org/sbml/level3/version1/layout/version1">
+ <layout:layout layout:id="Layout_1">
+ <layout:dimensions layout:width="400" layout:height="230"/>
+
+ <layout:listOfSpeciesGlyphs>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_Glucose" layout:species="Glucose" metaid="_SG1">
+ <layout:boundingBox layout:id="bb2">
+ <layout:position layout:x="105" layout:y="20"/>
+ <layout:dimensions layout:width="130" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+ <layout:speciesGlyph layout:id="SpeciesGlyph_G6P" layout:species="G6P">
+ <layout:boundingBox layout:id="bb5">
+ <layout:position layout:x="50" layout:y="190"/>
+ <layout:dimensions layout:width="270" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:speciesGlyph>
+
+
+
+ </layout:listOfSpeciesGlyphs>
+
+ <layout:listOfTextGlyphs>
+ <layout:textGlyph layout:id="TextGlyph_Glucose"
+ layout:originOfText="Glucose"
+ layout:graphicalObject="1SpeciesGlyph_Glucose"
+ layout:metaidRef="_SG1" layout:text="SBO:0000001">
+ <layout:boundingBox layout:id="bbA">
+ <layout:position layout:x="115" layout:y="20"/>
+ <layout:dimensions layout:width="110" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+ <layout:textGlyph layout:id="TextGlyph_G6P"
+ layout:originOfText="G6P"
+ layout:graphicalObject="SpeciesGlyph_G6P">
+ <layout:boundingBox layout:id="bbD">
+ <layout:position layout:x="60" layout:y="190"/>
+ <layout:dimensions layout:width="250" layout:height="20"/>
+ </layout:boundingBox>
+ </layout:textGlyph>
+
+
+
+ </layout:listOfTextGlyphs>
+ </layout:layout>
+ </layout:listOfLayouts>
+ </model>
+</sbml>
Added: trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021002-fail-01-01.xml
===================================================================
--- trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021002-fail-01-01.xml (rev 0)
+++ trunk/libsbml/src/sbml/packages/layout/validator/test/test-data/general-constraints/6021002-fail-01-01.xml 2013-07-26 15:08:02 UTC (rev 182...
[truncated message content] |