public MetadataFile(IPackageDocument document, string name) { if (document == null) { throw new ArgumentNullException("document"); } if (string.IsNullOrEmpty(name)) { throw new ArgumentException("name"); } _document = document; _name = name; }
public MetadataManifest(IPackageDocument document, string name) : base(document, name) { Graph.NamespaceMap.AddNamespace("pkg", new Uri("http://docs.oasis-open.org/ns/office/1.2/meta/pkg#")); Graph.NamespaceMap.AddNamespace("odf", new Uri("http://docs.oasis-open.org/ns/office/1.2/meta/odf#")); Graph.NamespaceMap.AddNamespace("rdf", new Uri("http://www.w3.org/1999/02/22-rdf-syntax-ns#")); _documentNode = Graph.CreateUriNode(); _rdfTypeNode = Graph.CreateUriNode("rdf:type"); _hasPartPredicateNode = Graph.CreateUriNode("pkg:hasPart"); _metadataFileTypeNode = Graph.CreateUriNode("pkg:MetadataFile"); Graph.Assert(_documentNode, _rdfTypeNode, _hasPartPredicateNode); }