[Bio] / Sprout / AttributesDBD.xml Repository:
ViewVC logotype

Diff of /Sprout/AttributesDBD.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1, Tue Nov 28 01:01:01 2006 UTC revision 1.2, Wed Nov 29 20:28:52 2006 UTC
# Line 21  Line 21 
21          </Field>          </Field>
22        </Fields>        </Fields>
23      </Entity>      </Entity>
24      <Entity name="Assignment" keyType="hash-string">      <Entity name="TargetObject" keyType="string">
25        <Notes>An [i]assignment[/i] represents the relationship between an attribute key and        <Notes>An [i]object[/i] represents a keyed thing to which an attribute can be assigned.
26        an object. The key is the digest of a string formed by the attribute key name, an equal sign,        In order to improve performance, this table has no data in it. It is simply required by
27        and the object ID. Since the key name cannot contain equal signs, the string is enough        the semantics of the database.</Notes>
       to uniquely identify an assignment.</Notes>  
       <Fields>  
         <Field name="object-id" type="string">  
           <Notes>This is the ID of the object to which the assignment is made.</Notes>  
         </Field>  
         <Field name="value" relation="AssignmentValue" type="text">  
           <Notes>Value assigned to the object for the specified key. There may be more than  
           one value assigned.</Notes>  
         </Field>  
       </Fields>  
       <Indexes>  
         <Index>  
           <Notes>This index allows the user to search for assignments with a particular value.</Notes>  
           <IndexFields>  
             <IndexField name="value" order="ascending" />  
           </IndexFields>  
         </Index>  
         <Index>  
           <Notes>This index allows the user to search for all assignments to a particular object.</Notes>  
           <IndexFields>  
             <IndexField name="object-id" order="ascending" />  
           </IndexFields>  
         </Index>  
       </Indexes>  
28      </Entity>      </Entity>
29    </Entities>    </Entities>
30    <Relationships>    <Relationships>
31      <Relationship name="IsInGroup" from="AttributeKey" to="AttributeGroup" arity="MM">      <Relationship name="IsInGroup" from="AttributeKey" to="AttributeGroup" arity="MM">
32        <Notes>This relationship connects an attribute key to the groups of which it is a member.</Notes>        <Notes>This relationship connects an attribute key to the groups of which it is a member.</Notes>
33      </Relationship>      </Relationship>
34      <Relationship name="IsKeyOf" from="AttributeKey" to="Assignment" arity="1M">      <Relationship name="HasValueFor" from="AttributeKey" to="TargetObject" arity="MM">
35        <Notes>This relationship connects an attribute key to its assignments.</Notes>        <Notes>This relationship connects an attribute key to its objects. It contains the
36          attribute values, and is therefore the primary data repository for the database.</Notes>
37          <Fields>
38            <Field name="value" type="text">
39              <Notes>This is the actual attribute value. Note that a single key/object pair may in fact
40              have many values, and therefore many entries in this table.</Notes>
41            </Field>
42          </Fields>
43      </Relationship>      </Relationship>
44    </Relationships>    </Relationships>
45  </Database>  </Database>

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3