NAME

WebService::Shutterstock::Image - Represent the set of information about a Shutterstock image as returned by the API

VERSION

version 0.003

SYNOPSIS

my $image = $shutterstock->image(59915404);
printf(
	"Image %d (%dx%d) - %s\n",
	$image->id,
	$image->size('huge')->{width},
	$image->size('huge')->{height},
	$image->description
);
print "Categories:\n";
foreach my $category ( @{ $image->categories } ) {
	printf( " - %s (%d)\n", $category->{category}, $category->{category_id} );
}

DESCRIPTION

This module serves as a proxy class for the data returned from a URL like http://api.shutterstock.com/images/15484942.json. Please look at that data structure for a better idea of exactly what each of the attributes in this class contains.

ATTRIBUTES

id

The ID of this image on the Shutterstock system

categories

ArrayRef of category names and IDs.

description

enhanced_license_available

Boolean

illustration

Boolean

is_vector

Boolean

keywords

ArrayRef of keywords.

model_release

Details regarding

r_rated

Boolean

sizes

Returns a HashRef of information about the various sizes for the image.

submitter

Name of the individual who submitted the image to Shutterstock.

submitter_id

ID of the submitter.

vector_type

For a JPG image, this is undef. For a vector image, this would be a value like "eps".

web_url

A URL for the main page on Shutterstock's site for this image.

METHODS

similar

Returns an ArrayRef of WebService::Shutterstock::Image objects similar to the current image.

size

Returns details for a specific size. Some sizes provide just dimensions (small, medium, large). Other sizes include a URL for the image as well (thumb_small, thumb_large).

AUTHOR

Brian Phillips <bphillips@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2012 by Brian Phillips and Shutterstock, Inc. (http://shutterstock.com).

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.