summaryrefslogtreecommitdiff
path: root/fml/lib/IO/Adapter/UnixGroup.pm
diff options
context:
space:
mode:
authorfukachan <fukachan>2001-01-28 13:08:15 +0000
committerfukachan <fukachan>2001-01-28 13:08:15 +0000
commit653d890ecebb2827e05836fc50f75678c01bac93 (patch)
tree2be0e74cc27eaa2e26b547e348e18561495792db /fml/lib/IO/Adapter/UnixGroup.pm
parentb9397db8eec7bf2f61cb3974dd1fb39dbc31a2f4 (diff)
downloadfml8-653d890ecebb2827e05836fc50f75678c01bac93.tar.gz
fml8-653d890ecebb2827e05836fc50f75678c01bac93.tar.bz2
fml8-653d890ecebb2827e05836fc50f75678c01bac93.zip
move initialization codes on NIS and etc/group to each subclass
Diffstat (limited to 'fml/lib/IO/Adapter/UnixGroup.pm')
-rw-r--r--fml/lib/IO/Adapter/UnixGroup.pm66
1 files changed, 66 insertions, 0 deletions
diff --git a/fml/lib/IO/Adapter/UnixGroup.pm b/fml/lib/IO/Adapter/UnixGroup.pm
new file mode 100644
index 00000000..f12e03d6
--- /dev/null
+++ b/fml/lib/IO/Adapter/UnixGroup.pm
@@ -0,0 +1,66 @@
+#-*- perl -*-
+#
+# Copyright (C) 2001 Ken'ichi Fukamachi
+# All rights reserved. This program is free software; you can
+# redistribute it and/or modify it under the same terms as Perl itself.
+#
+# $Id$
+# $FML$
+#
+
+package IO::Adapter::UnixGroup;
+
+use strict;
+use vars qw(@ISA @EXPORT @EXPORT_OK $AUTOLOAD);
+use Carp;
+use IO::Adapter::Array;
+
+@ISA = qw(IO::Adapter::Array);
+
+sub configure
+{
+ my ($self, $me) = @_;
+ my ($type) = ref($self) || $self;
+
+ # emulate an array on memory
+ my (@x) = getgrnam( $me->{_name} );
+ my (@members) = split ' ', $x[3];
+ $me->{_array_reference} = \@members;
+}
+
+
+
+=head1 NAME
+
+IO::Adapter::UnixGroup.pm - what is this
+
+=head1 SYNOPSIS
+
+=head1 DESCRIPTION
+
+=head1 CLASSES
+
+=head1 METHODS
+
+=item C<new()>
+
+... what is this ...
+
+=head1 AUTHOR
+
+Ken'ichi Fukamachi
+
+=head1 COPYRIGHT
+
+Copyright (C) 2001 Ken'ichi Fukamachi
+
+All rights reserved. This program is free software; you can
+redistribute it and/or modify it under the same terms as Perl itself.
+
+=head1 HISTORY
+
+IO::Adapter::UnixGroup.pm appeared in fml5.
+
+=cut
+
+1;