[Bio] / FigWebPages / Attributes.html Repository:
ViewVC logotype

Diff of /FigWebPages/Attributes.html

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

revision 1.6, Tue Jul 19 04:54:22 2005 UTC revision 1.7, Sat Oct 22 17:43:49 2005 UTC
# Line 271  Line 271 
271  <p>  <p>
272  </p>  </p>
273  <h3><a name="key_info">key_info</a></h3>  <h3><a name="key_info">key_info</a></h3>
274  <p>Access a reference to an array of [single, explanation]</p>  <p>Access a hash of key information. The data that are returned are:</p>
275    <table>
276    <tr><td>hash key name</td><td>what is it</td><td>data type</td></tr>
277    <tr><td>single</td><td>Whether the attribute can handle only a single data point</td><td>[boolean]</td></tr>
278    <tr><td>description</td><td>Explanation of key</td><td>[free text]</td></tr>
279    <tr><td>readonly</td><td>whether to allow read/write</td><td>[boolean]</td></tr>
280    <tr><td>is_cv</td><td>attribute is a cv term</td><td>[boolean]</td></tr>
281    </table>
282    
283  <p>Single is a boolean, if it is true only the last value returned should be used. Note that the other methods willl still return all the values, it is upto the implementer to ensure that only the last value is used.</p>  <p>Single is a boolean, if it is true only the last value returned should be used. Note that the other methods willl still return all the values, it is upto the implementer to ensure that only the last value is used.</p>
284  <p>Explanation is a user-derived explanation that can be defined.</p>  
285  <p>if a reference to an array is provided, along with the key, those values will be set.</p>  <p>Explanation is a user-derived explanation that can be free text</p>
286  <p>e.g.  
287  $fig-&gt;key_info($key, \@data); # set the data  <p>If a reference to a hash is provided, along with the key, those values will be set to the attribute_keys file</p>
288  $data=$fig-&gt;key_info($key); # get the data</p>  
289    <p>Returns an empty hash if the key is not provieded or doesn't exist</p>
290    
291    <p>e.g.<br />
292    $fig->key_info($key, \%data); # set the data<br />
293    $data=$fig->key_info($key); # get the data<br />
294    </p>
295    
296    
297    
298  <p>  <p>
299  </p>  </p>
300  <h3><a name="get_key_value">get_key_value</a></h3>  <h3><a name="get_key_value">get_key_value</a></h3>

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3