Changeset 41 for LATMOS-Accounts
- Timestamp:
- 04/25/09 04:47:06 (15 years ago)
- Location:
- LATMOS-Accounts
- Files:
-
- 2 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LATMOS-Accounts/lib/LATMOS/Accounts.pm
r34 r41 75 75 } 76 76 77 sub config_sync_base { 78 my ($self, $from) = @_; 79 return split(/ /, $self->val($from, 'push', '')); 80 } 81 77 82 1; 78 83 … … 116 121 =head1 AUTHOR 117 122 118 Thauvin Olivier, E<lt>olivier.thauvin .ipsl.fr@localdomainE<gt>123 Thauvin Olivier, E<lt>olivier.thauvin@latmosipsl.frE<gt> 119 124 120 125 =head1 COPYRIGHT AND LICENSE -
LATMOS-Accounts/lib/LATMOS/Accounts/Bases.pm
r28 r41 39 39 eval "require LATMOS::Accounts::Bases::$pclass;"; 40 40 if ($@) { return } # error message ? 41 return "LATMOS::Accounts::Bases::$pclass"->new(%options); 41 my $base = "LATMOS::Accounts::Bases::$pclass"->new(%options); 42 $base->{_type} = lc($pclass); 43 $base 44 } 45 46 sub type { 47 $_[0]->{_type}; 42 48 } 43 49 … … 76 82 my $pclass = $self->_load_obj_class($otype) or return; 77 83 $pclass->_get_field_name($c_fields); 84 } 85 86 =head2 list_supported_objects(@otype) 87 88 Return a list of supported object 89 90 @type is an additionnal list of objects to check 91 92 =cut 93 94 sub list_supported_objects { 95 my ($self, @otype) = @_; 96 return grep { $self->is_supported_object($_) } 97 (qw(user group), @otype); 98 } 99 100 =head2 is_supported_object($otype) 101 102 Return true is object type $otype is supported 103 104 =cut 105 106 sub is_supported_object { 107 my ($self, $otype) = @_; 108 return $self->_load_obj_class($otype) ? 1 : 0; 78 109 } 79 110
Note: See TracChangeset
for help on using the changeset viewer.