⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 text.pm

📁 网页留言本,比一般的留言簿管用
💻 PM
字号:
# $Id: Text.pm 4532 2004-05-11 05:15:40Z ezra $package XML::XPath::Node::Text;use strict;use vars qw/@ISA/;@ISA = ('XML::XPath::Node');package XML::XPath::Node::TextImpl;use vars qw/@ISA/;@ISA = ('XML::XPath::NodeImpl', 'XML::XPath::Node::Text');use XML::XPath::Node ':node_keys';sub new {    my $class = shift;    my ($text) = @_;            my $pos = XML::XPath::Node->nextPos;                my @vals;        @vals[node_global_pos, node_text] = ($pos, $text);    my $self = \@vals;            bless $self, $class;}sub getNodeType { TEXT_NODE }sub isTextNode { 1; }sub appendText {    my $self = shift;    my ($text) = @_;    $self->[node_text] .= $text;}sub getNodeValue {    my $self = shift;    $self->[node_text];}sub getData {    my $self = shift;    $self->[node_text];}sub setNodeValue {    my $self = shift;    $self->[node_text] = shift;}sub _to_sax {    my $self = shift;    my ($doch, $dtdh, $enth) = @_;        $doch->characters( { Data => $self->getValue } );}sub string_value {    my $self = shift;    $self->[node_text];}sub toString {    my $self = shift;    XML::XPath::Node::XMLescape($self->[node_text], "<&");}1;__END__=head1 NAMEText - an XML text node=head1 API=head2 new ( text )Create a new text node.=head2 getValue / getDataReturns the text=head2 string_valueReturns the text=head2 appendText ( text )Adds the given text string to this node.=cut

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -