X-Git-Url: http://git.indexdata.com/?p=irspy-moved-to-github.git;a=blobdiff_plain;f=lib%2FZOOM%2FPod.pm;h=5faee4d7cb74098b02ea26b4385b406e22d87bea;hp=5c554ec544a510aa4e538bb06b9909106403283e;hb=0e124b9481a9b50b4d2110bdb264d31e0b35663f;hpb=087d286130ff54c827c1d490ee9be55286476882 diff --git a/lib/ZOOM/Pod.pm b/lib/ZOOM/Pod.pm index 5c554ec..5faee4d 100644 --- a/lib/ZOOM/Pod.pm +++ b/lib/ZOOM/Pod.pm @@ -1,4 +1,4 @@ -# $Id: Pod.pm,v 1.18 2006-07-25 16:51:22 mike Exp $ +# $Id: Pod.pm,v 1.22 2006-10-06 11:33:07 mike Exp $ package ZOOM::Pod; @@ -8,7 +8,7 @@ use warnings; use ZOOM; BEGIN { - # Just register the name + # Just register the names: this doesn't turn the levels on ZOOM::Log::mask_str("pod"); ZOOM::Log::mask_str("pod_unhandled"); } @@ -111,6 +111,21 @@ sub new { }, $class; } + +=head2 connections() + + @c = $pod->connections(); + +Returns a list of the connection objects in the pod. + +=cut + +sub connections { + my $this = shift(); + return @{ $this->{conn} } +} + + =head2 option() $oldElemSet = $pod->option("elementSetName"); @@ -205,12 +220,25 @@ sub callback { my($event, $sub) = @_; my $old = $this->{callback}->{$event}; - $this->{callback}->{$event} = $sub - if defined $sub; + $this->{callback}->{$event} = $sub; return $old; } +=head2 remove_callbacks() + + $pod->remove_callbacks(); + +Removes all registed callbacks from the pod. This is useful when the +pod has completed one operation and is about to start the next. + +=cut + +sub remove_callbacks { + my $this = shift(); + $this->{callback} = {}; +} + =head2 search_pqf() $pod->search_pqf("@attr 1=1003 wedel");