[Bio] / FigKernelPackages / UserData.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/UserData.pm

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

revision 1.5, Tue Feb 21 10:57:13 2006 UTC revision 1.6, Thu Dec 6 13:59:34 2007 UTC
# Line 90  Line 90 
90    
91  =head3 new  =head3 new
92    
93  C<< my $userData = UserData->new($user, $fig); >>      my $userData = UserData->new($user, $fig);
94    
95  Construct the capabilities object for a specified user.  Construct the capabilities object for a specified user.
96    
# Line 129  Line 129 
129    
130  =head3 GetCapability  =head3 GetCapability
131    
132  C<< my $level = $userData->GetCapability($objectID, $objectType); >>      my $level = $userData->GetCapability($objectID, $objectType);
133    
134  Get this user's access level for the specified object-- either C<RW> (full access),  Get this user's access level for the specified object-- either C<RW> (full access),
135  C<RO> (read-only), or C<NO> (no access).  C<RO> (read-only), or C<NO> (no access).
# Line 174  Line 174 
174    
175  =head3 GetPreference  =head3 GetPreference
176    
177  C<< my $value = $userData->GetPreference($key); >>      my $value = $userData->GetPreference($key);
178    
179  Return the user's preference value for the specified key.  Return the user's preference value for the specified key.
180    
# Line 207  Line 207 
207    
208  =head3 SetCapabilities  =head3 SetCapabilities
209    
210  C<< $userData->SetCapabilities(\%groupMap); >>      $userData->SetCapabilities(\%groupMap);
211    
212  Set capabilities for this user. This does not replace all existing capabilities.  Set capabilities for this user. This does not replace all existing capabilities.
213  Instead, the capabilities specified in the group map are updated or deleted,  Instead, the capabilities specified in the group map are updated or deleted,
# Line 244  Line 244 
244    
245  =head3 SetPreferences  =head3 SetPreferences
246    
247  C<< $userData->SetPreferences(\%preferences); >>      $userData->SetPreferences(\%preferences);
248    
249  Set preferences for this user. This does not replace all existing preferences.  Set preferences for this user. This does not replace all existing preferences.
250  Instead, the preferences specified in the map are updated or deleted, and any  Instead, the preferences specified in the map are updated or deleted, and any
# Line 284  Line 284 
284    
285  =head3 SetDefault  =head3 SetDefault
286    
287  C<< $userData->SetDefault($objectID, $objectType, $group, $level); >>      $userData->SetDefault($objectID, $objectType, $group, $level);
288    
289  Set the group and default access level for the specified object. This update  Set the group and default access level for the specified object. This update
290  takes place immediately.  takes place immediately.
# Line 323  Line 323 
323    
324  =head3 SaveChanges  =head3 SaveChanges
325    
326  C<< $userData->SaveChanges(); >>      $userData->SaveChanges();
327    
328  Store accumulated preference and capability changes.  Store accumulated preference and capability changes.
329    
# Line 346  Line 346 
346    
347  =head3 ParseCategory  =head3 ParseCategory
348    
349  C<< my $category = UserData::ParseCategory($key); >>      my $category = UserData::ParseCategory($key);
350    
351  Return the category name from the specified preference key. If no category is  Return the category name from the specified preference key. If no category is
352  specified, an error will occur.  specified, an error will occur.
# Line 384  Line 384 
384    
385  =head3 GetCategoryHash  =head3 GetCategoryHash
386    
387  C<< my $categoryHash = $self->GetCategoryHash($category); >>      my $categoryHash = $self->GetCategoryHash($category);
388    
389  Return the hash for the specified category. If it is not in memory, it  Return the hash for the specified category. If it is not in memory, it
390  will be read in.  will be read in.
# Line 441  Line 441 
441    
442  =head3 GetDefault  =head3 GetDefault
443    
444  C<< my ($group, $level) = $fig->GetDefault($objectID, $objectType); >>      my ($group, $level) = $fig->GetDefault($objectID, $objectType);
445    
446  Return the group name and default access level for the specified object.  Return the group name and default access level for the specified object.
447    
# Line 468  Line 468 
468    
469  =head3 GetPreferences  =head3 GetPreferences
470    
471  C<< my $preferences = $fig->GetPreferences($userID, $category); >>      my $preferences = $fig->GetPreferences($userID, $category);
472    
473  Return a map of preference keys to values for the specified user in the  Return a map of preference keys to values for the specified user in the
474  specified category.  specified category.
# Line 497  Line 497 
497    
498  =head3 GetCapabilities  =head3 GetCapabilities
499    
500  C<< my $level = $fig->GetCapabilities($userID); >>      my $level = $fig->GetCapabilities($userID);
501    
502  Return a map of group names to access levels (C<RW>, C<RO>, or C<NO>) for the  Return a map of group names to access levels (C<RW>, C<RO>, or C<NO>) for the
503  specified user.  specified user.
# Line 517  Line 517 
517    
518  =head3 AllowsUpdates  =head3 AllowsUpdates
519    
520  C<< my $flag = $fig->AllowsUpdates(); >>      my $flag = $fig->AllowsUpdates();
521    
522  Return TRUE if this access object supports updates, else FALSE. If the access object  Return TRUE if this access object supports updates, else FALSE. If the access object
523  does not support updates, none of the B<SetXXXX> methods will be called.  does not support updates, none of the B<SetXXXX> methods will be called.
524    
525  =head3 SetDefault  =head3 SetDefault
526    
527  C<< $fig->SetDefault($objectID, $objectType, $group, $level); >>      $fig->SetDefault($objectID, $objectType, $group, $level);
528    
529  Set the group and default access level for the specified object.  Set the group and default access level for the specified object.
530    
# Line 553  Line 553 
553    
554  =head3 SetCapabilities  =head3 SetCapabilities
555    
556  C<< $fig->SetCapabilities($userID, \%groupLevelMap); >>      $fig->SetCapabilities($userID, \%groupLevelMap);
557    
558  Set the access levels by the specified user for the specified groups.  Set the access levels by the specified user for the specified groups.
559    
# Line 577  Line 577 
577    
578  =head3 SetPreferences  =head3 SetPreferences
579    
580  C<< $fig->SetPreferences($userID, \%preferenceMap); >>      $fig->SetPreferences($userID, \%preferenceMap);
581    
582  Set the preferences for the specified user.  Set the preferences for the specified user.
583    
# Line 601  Line 601 
601    
602  =head3 CleanupUserData  =head3 CleanupUserData
603    
604  C<< $fig->CleanupUserData(); >>      $fig->CleanupUserData();
605    
606  Release any data being held in memory for use by the UserData object.  Release any data being held in memory for use by the UserData object.
607    

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

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3