OpenDocumentPHP
[ class tree: OpenDocumentPHP ] [ index: OpenDocumentPHP ] [ all elements ]

Class: MetaDocument

Source Location: /meta/MetaDocument.php

Class Overview

DOMDocument
   |
   --AbstractDocument
      |
      --MetaDocument

MetaDocument class.


Author(s):

  • Norman Markgraf (nmarkgraf(at)user.sourceforge.net)

Version:

  • $Revision: 139 $

Copyright:

  • Copyright in 2006, 2007 by The OpenDocumentPHP Team

Variables

Methods


Inherited Constants

Inherited Variables

Inherited Methods

Class: AbstractDocument

AbstractDocument::__construct()
Constructor method.
AbstractDocument::createDCElement()
Create an DOMElement in the DC namespace with tag $tag.
AbstractDocument::createDefaultStyleElement()
Create an ODPElement as '<style:default-style>'.
AbstractDocument::createGraphicPropertiesElement()
Create an ODPElement as '<style:graphic-properties>'.
AbstractDocument::createManifestElement()
Create an DOMElement in the Manifest namespace with tag $tag.
AbstractDocument::createMetaElement()
Create an DOMElement in the Meta namespace with tag $tag.
AbstractDocument::createOfficeElement()
Create an DOMElement in the Office namespace with tag $tag.
AbstractDocument::createParagraphPropertiesElement()
Create an ODPElement as '<style:paragraph-properties>'.
AbstractDocument::createStyleElement()
Create an DOMElement in the Meta namespace with tag $tag.
AbstractDocument::createStyleStyleElement()
Create an ODPElement as '<style:style>'.
AbstractDocument::createTextPropertiesElement()
Create an ODPElement as '<style:text-properties>'.
AbstractDocument::getElementNS()
Retrieve the value of an element by its namespace and tag.
AbstractDocument::initXpath()
Initialize xpath. You must do this before using xpath.
AbstractDocument::loadHTML()
This function is not needed, so we always return false!
AbstractDocument::loadHTMLFile()
This function is not needed, so we always return false!
AbstractDocument::saveHTML()
This function is not needed, so we always return false!
AbstractDocument::saveHTMLFile()
This function is not needed, so we always return false!
AbstractDocument::saveXML()
Dumps the internal XML tree back into a string.
AbstractDocument::_setRoot()
Set the root Element of this document.

Class Details

[line 91]
MetaDocument class.

In this container class we will store all the meta data and build a DOM document out of it.

You can find more informations about this in the OpenDocument format handbook v1.0 page 40ff.

Also you should now something about Dublin Meta core data. Take a look at the Dublin core webpage or read Dublin core in Wikipedia, Dublin core qualifiers or Dublin core in german Wikipedia.

To put some dublin core meta data in the MetaDocument, request a DublinCoreFragment and add the meta data there.

You can also add OpenDocument meta data to the MetaFragment.

This is an example of a meta.xml file:

  1.  <?xml version="1.0" encoding="UTF-8"?>
  2.  <office:document-meta
  3.       xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0"
  4.       xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0"
  5.       xmlns:dc="http://purl.org/dc/elements/1.1/"
  6.       xmlns:xlink="http://www.w3.org/1999/xlink">
  7.    <office:meta>
  8.      <meta:generator>OpenOffice.org/1.9.118$Win32 OpenOffice.org_project/680m118$Build-8936</meta:generator>
  9.      <meta:initial-creator>Peter Funny</meta:initial-creator>
  10.      <meta:creation-date>2005-09-27T16:53:48</meta:creation-date>
  11.      <dc:creator>Peter Funny</dc:creator>
  12.      <dc:date>2005-09-29T18:12:57</dc:date>
  13.      <meta:printed-by>Peter Funny</meta:printed-by>
  14.      <meta:print-date>2005-09-29T17:57:42</meta:print-date>
  15.      <dc:language>en-EN</dc:language>
  16.      <meta:editing-cycles>11</meta:editing-cycles>
  17.      <meta:editing-duration>PT6H11M44S</meta:editing-duration>
  18.      <meta:user-defined meta:name="Info 1"/>
  19.      <meta:user-defined meta:name="Info 2"/>
  20.      <meta:user-defined meta:name="Info 3"/>
  21.      <meta:user-defined meta:name="Info 4"/>
  22.      <meta:document-statistic
  23.            meta:table-count="0"
  24.            meta:image-count="4"
  25.            meta:object-count="0"
  26.            meta:page-count="5"
  27.            meta:paragraph-count="92"
  28.            meta:word-count="1460"
  29.            meta:character-count="10405"/>
  30.    </office:meta>
  31.  </office:document-meta>




Tags:

author:  Norman Markgraf (nmarkgraf(at)user.sourceforge.net)
version:  $Revision: 139 $
copyright:  Copyright in 2006, 2007 by The OpenDocumentPHP Team
link:  http://www.oasis-open.org/committees/download.php/20493/UCR.pdf OpenDocument Metadata Use Cases and Requirements
since:  0.5.0 - 08.02.2007
license:  GNU General Public License 2.0.


[ Top ]


Class Variables

$root =

[line 123]

Link to the DOMElement which is the root of this DOM document.



Tags:

since:  0.5.0 - 08.02.2007
access:  protected

Type:   DOMElement
Overrides:   Array


[ Top ]



Class Methods


constructor __construct [line 132]

MetaDocument __construct( )

Construtor method.

Creates two container classes to store/get dublin core and open document meta datas.




Tags:

since:  0.5.0 - 08.02.2007


Overrides AbstractDocument::__construct() (Constructor method.)

[ Top ]

method getDublinCoreFragment [line 147]

DublinCoreFragment getDublinCoreFragment( )

Retrieve a DublinCoreFragment to store/get dublin core meta date in it.



Tags:

since:  0.5.0 - 08.02.2007
access:  public


[ Top ]

method getMetaFragment [line 157]

MetaFragment getMetaFragment( )

Retrieve a MetaFragment to store/get opendocument meta data in it.



Tags:

since:  0.5.0 - 08.02.2007
access:  public


[ Top ]

method loadXML [line 166]

void loadXML( $source)

Loads an meta document into this MetaDocument.



Tags:

since:  0.5.2 - 22.02.2007
access:  public


Parameters:

   $source  

[ Top ]


Documentation generated on Tue, 12 Jun 2007 10:00:08 +0200 by phpDocumentor 1.3.2