fleshed out some commands (particularly flag setting and unsetting)
[spider.git] / cmd / show / channel.pl
1 #
2 # show the channel status
3 #
4 # $Id$
5 #
6
7 my ($self, $line) = @_;
8 my @list = /\s+/, $line;                  # generate a list of callsigns
9 @list = ($self->call) if (!@list || $self->priv < 9);  # my channel if no callsigns
10
11 my $call;
12 my @out;
13 foreach $call (@list) {
14   $call = uc $call;
15   my $ref = DXChannel->get($call);
16   if ($ref) {
17     @out = print_all_fields($self, $ref, "Channe Information $call");
18   } else {
19     return (0, "Channel: $call not found") if !$ref;
20   }
21   push @out, "" if @list > 1;
22 }
23
24 return (1, @out);
25
26