File: document.rd

package info (click to toggle)
libdb-ruby 0.6.5-2
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 2,596 kB
  • ctags: 3,978
  • sloc: ansic: 13,984; cpp: 8,739; ruby: 7,864; sh: 47; makefile: 6
file content (101 lines) | stat: -rw-r--r-- 1,867 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
=begin
== BDB::XML::Document

A Document is the unit of storage within a Container. A document consists
of content, a name, and a set of metadata attributes.

The document content is a byte stream. It must be well formed XML, 
but need not be valid.

included module : Enumerable

=== Methods
   
--- self[name]

    Returns the value of the specified metadata.

--- self[name] =  val

    Set the value of the specified metadata.

   
--- content

    Return the content of the document

   
--- content = val

    Set the content of the document


--- each {|uri, name, value| ... }
--- each_metadata {|uri, name, value| ... }

    Iterate over all metadata
   
--- get_metadata(uri, name)
--- get_metadata(name)
--- get(uri, name)
--- get(name)
    
    Get the identified metadata from the document.

    * ((|uri|))
      The namespace within which the name resides.
    * ((|name|))
      The name of the metadata attribute to be retrieved.

--- manager

    Return the manager

--- name

    Return the name of the document
   
--- name = val

    Set the name of the document


--- remove_metadata(uri, name)
--- remove_metadata(name)
    
    Remove the identified metadata from the document.

    * ((|uri|))
      The namespace within which the name resides.
    * ((|name|))
      The name of the metadata attribute to be removed.
      
   
--- set_metadata(name, value)
--- set_metadata(uri, name, value)
--- set(name, value)
--- set(uri, name, value)
    
    Set the identified metadata from the document.

    * ((|uri|))
      The namespace within which the name resides.
    * ((|name|))
      The name of the metadata attribute to be set.
    * ((|value|))
      an XML::Value object


--- to_s
    Return the document as a String object


--- to_str
    same than ((|to_s|))


--- event_reader

    Retrieve content as an XML::EventReader.

=end