package LaTeXML::Package::Pool;
use strict;
use LaTeXML::Package;
#RequirePackage('svninfo');
#RequirePackage('dcm');

RegisterNamespace('v'=>"http://omdoc.org/ontology/versioning#");
RegisterDocumentNamespace('v'=>"http://omdoc.org/ontology/versioning#");

DefConstructor('\VMversion{}',
	       "<omdoc:link rel='v:atRevision' stex:srcref='#locator' v:dummy='to ensure the namespace'>"
	      .  "<omdoc:meta property='v:revisionId'>#1</omdoc:meta>"
	      ."</omdoc:link>");
DefConstructor('\VMdocstate{}',
	       "<omdoc:link rel='v:hasState' stex:srcref='#locator' v:dummy='to ensure the namespace'>"
	      .  "<omdoc:meta property='v:docState'>#1</omdoc:meta>"
	      ."</omdoc:link>");
DefConstructor('\VMcreated{}',
	       "<dc:date action='created'>#1</dc:date>");
DefConstructor('\VMresponsible{}',
	       "<omdoc:link rel='v:responsible' href='#1' v:dummy='to ensure the namespace'/>");

Tag('omdoc:resource', autoClose=>1);
Tag('omdoc:meta', autoClose=>1);

DefEnvironment('{VMchangelist}',"<omdoc:link rel='v:hasRevision' stex:srcref='#locator'>#body</omdoc:link>");
DefEnvironment('{VMchange}{}{}{}',
	       "<omdoc:resource typeof='v:Revision' v:dummy='to ensure the namespace'>"
	      .  "<omdoc:meta property='v:revisionId'>#2</omdoc:meta>"
	      .  "<omdoc:meta property='dc:date'>#1</omdoc:meta>"
	      .  "<omdoc:link rel='dc:creator' href='#3'/>"
	      .  "<omdoc:meta property='dc:description'>#body</omdoc:meta>"
              ."</omdoc:resource>");

DefEnvironment('{VMcertification}',"<omdoc:link rel='v:hasCertification' stex:srcref='#locator'>#body</omdoc:link>");
DefEnvironment('{VMcertified}{}{}{}{}',
	       "<omdoc:resource typeof='v:Certification' stex:srcref='#locator' v:dummy='to ensure the namespace'>"
	      .  "<omdoc:meta property='v:revisionId'>#2</omdoc:meta>"
	      .  "<omdoc:meta property='dc:date'>#1</omdoc:meta>"
	      .  "<omdoc:link rel='dc:creator' href='#3'/>"
	      .  "<omdoc:link rel='v:docState' href='#4'/>"
	      .  "<omdoc:meta property='dc:description'>#body</omdoc:meta>"	
	      ."</omdoc:resource>");

1;
