]> dxcluster.org Git - spider.git/commitdiff
add has_xml et al.
authorminima <minima>
Tue, 10 Jan 2006 22:31:57 +0000 (22:31 +0000)
committerminima <minima>
Tue, 10 Jan 2006 22:31:57 +0000 (22:31 +0000)
perl/DXXml.pm

index 968b6148cf04f48d60e3564bd1292891eec19e37..e3c5f270276db1f041d4164e811009fce0633bbf 100644 (file)
@@ -122,7 +122,23 @@ sub toxml
        $self->{id} ||= nextid();
 
        my ($name) = ref $self =~ /::(\w+)$/;
-       my $s = $xs->XMLout($self, RootName =>$name, NumericEscape=>1);
+       my $s = $xs->XMLout($self, RootName =>lc $name, NumericEscape=>1);
        return $self->{'-xml'} = $s;
 }
+
+sub has_xml
+{
+       return exists $_[0]->{'-xml'};
+}
+
+sub has_pcxx
+{
+       return exists $_[0]->{'-pcxx'};
+}
+
+sub has_cmd
+{
+       return exists $_[0]->{'-cmd'};
+}
+
 1;