cvsuser 02/03/19 14:42:30
Modified: P5EEx/Blue/P5EEx/Blue P5EE.pm
Log:
added printargs() for AOP entry/exit debugging
Revision Changes Path
1.10 +58 -1 p5ee/P5EEx/Blue/P5EEx/Blue/P5EE.pm
Index: P5EE.pm
===================================================================
RCS file: /cvs/public/p5ee/P5EEx/Blue/P5EEx/Blue/P5EE.pm,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -w -r1.9 -r1.10
--- P5EE.pm 2 Mar 2002 03:07:46 -0000 1.9
+++ P5EE.pm 19 Mar 2002 22:42:30 -0000 1.10
@@ -1,6 +1,6 @@
#############################################################################
-## $Id: P5EE.pm,v 1.9 2002/03/02 03:07:46 spadkins Exp $
+## $Id: P5EE.pm,v 1.10 2002/03/19 22:42:30 spadkins Exp $
#############################################################################
package P5EEx::Blue::P5EE;
@@ -137,6 +137,12 @@
=item * Class Group: L<C<LogChannel>|P5EEx::Blue::LogChannel>
- a logging channel through which messages may be logged
+=item * Class Group: L<C<SharedDatastore>|P5EEx::Blue::SharedDatastore>
+ - a data storage area which is shared between processes
+
+=item * Class Group: L<C<SharedResourceSet>|P5EEx::Blue::SharedResourceSet>
+ - a set of shared resources which may be locked for exclusive access
+
=back
=cut
@@ -425,6 +431,57 @@
}
$self->context($args)->config();
+}
+
+#############################################################################
+# printargs()
+#############################################################################
+
+=head2 printargs()
+
+ * Signature: P5EEx::Blue::P5EE->printargs($depth, $skipatend, @args);
+ * Param: $depth integer [in]
+ * Param: $skipatend integer [in]
+ * Param: @args any [in]
+ * Return: void
+ * Throws: none
+ * Since: 0.01
+
+=cut
+
+sub printargs {
+ my $depth = shift;
+ my $skipatend = shift;
+ my ($narg);
+ for ($narg = 0; $narg <= $#_ - $skipatend; $narg++) {
+ print "," if ($narg);
+ if (ref($_[$narg]) eq "") {
+ print $_[$narg];
+ }
+ elsif (ref($_[$narg]) eq "ARRAY") {
+ print "[";
+ if ($depth <= 1) {
+ print join(",", @{$_[$narg]});
+ }
+ else {
+ &printdepth($depth-1, 0, @{$_[$narg]});
+ }
+ print "]";
+ }
+ elsif (ref($_[$narg]) eq "HASH") {
+ print "{";
+ if ($depth <= 1) {
+ print join(",", %{$_[$narg]});
+ }
+ else {
+ &printdepth($depth-1, 0, %{$_[$narg]});
+ }
+ print "}";
+ }
+ else {
+ print $_[$narg];
+ }
+ }
}
=head1 ACKNOWLEDGEMENTS