| 1 | package Metaweb::Result; | ||
| 2 | |||
| 3 | 3 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 4 | 3 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | =head1 NAME | ||
| 7 | |||
| 8 | Metaweb::Result - Result set from a Metaweb query | ||
| 9 | |||
| 10 | =head1 SYNOPSIS | ||
| 11 | |||
| 12 | my $mw = Metaweb->new($args); | ||
| 13 | $mw->login(); | ||
| 14 | |||
| 15 | my $result = $mw->query($name, $query_hash); | ||
| 16 | # $result isa Metaweb::Result | ||
| 17 | |||
| 18 | use Data::Dumper; | ||
| 19 | print Dumper $result; | ||
| 20 | |||
| 21 | =head1 DESCRIPTION | ||
| 22 | |||
| 23 | This class doesn't do much of anything yet. It just gives you an object | ||
| 24 | you can treat as a hashref. | ||
| 25 | |||
| 26 | =head2 new() | ||
| 27 | |||
| 28 | Simple constructor. Takes a result as a perl data structure and | ||
| 29 | basically just turns it into a Metaweb::Result object. | ||
| 30 | |||
| 31 | =cut | ||
| 32 | |||
| 33 | 0 | ▶ | sub new { |
|
Subroutine
new: not called CC=1 SCAR=6.9
Pod
documented
| |||
| 34 | 0 | my ($class, $result) = @_; | |
| 35 | 0 | my $self = { content => $result }; | |
| 36 | 0 | bless $self, $class; | |
| 37 | 0 | return $self; | |
| 38 | } | ||
| 39 | |||
| 40 | =head1 SEE ALSO | ||
| 41 | |||
| 42 | L<Metaweb> | ||
| 43 | |||
| 44 | =cut | ||
| 45 | |||
| 46 | 3 | 1; | |