| Google-Chart documentation | Contained in the Google-Chart distribution. |
Google::Chart::QueryComponent::Simple - Simplified Google::Chart Query Component
package MyStuff; use Moose; with 'Google::Chart::QueryComponent::Simple';
| Google-Chart documentation | Contained in the Google-Chart distribution. |
# $Id$ package Google::Chart::QueryComponent::Simple; use Moose::Role; use URI::Escape (); with 'Google::Chart::QueryComponent'; requires qw(parameter_name parameter_value); no Moose; sub as_query { my $self = shift; return wantarray ? ($self->parameter_name, $self->parameter_value) : join('=', $self->parameter_name, URI::Escape::uri_escape($self->parameter_value)) ; }; 1; __END__