Data::XML::Variant::Output - Output class for Data::XML::Variant


Data-XML-Variant documentation Contained in the Data-XML-Variant distribution.

Index


Code Index:

NAME

Top

Data::XML::Variant::Output - Output class for Data::XML::Variant

VERSION

Top

Version 0.01

SYNOPSIS

Top

Do not use this class directly. This class is merely a convenient way of "tagging" data as already having been processed (for example, escapes already applied).

EXPORT

Top

None.

METHODS

Top

new

 my $output = Data::XML::Variant::Output->new($string);

Passed a string, the constructor will return an object with overloaded stringification. When printed, it will print the string it contains.

output

  print $output->output;

Returns the $string passed to new.

AUTHOR

Top

Curtis "Ovid" Poe, <ovid@cpan.org>

BUGS

Top

Please report any bugs or feature requests to bug-data-xml-variant@rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Data-XML-Variant. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

ACKNOWLEDGEMENTS

Top

COPYRIGHT & LICENSE

Top


Data-XML-Variant documentation Contained in the Data-XML-Variant distribution.
package Data::XML::Variant::Output;

use strict;
use overload
  '""'     => sub { shift->output },
  fallback => 1;


our $VERSION = '0.01';

sub new {
    my ( $class, $string ) = @_;
    bless \$string, $class;
}

##############################################################################

sub output { ${$_[0]} }

1;