1# -*- perl -*-
2# !!! DO NOT EDIT !!!
3# This file was automatically generated.
4package Net::Amazon::Validate::ItemSearch::uk::Jewelry;
5
6use 5.006;
7use strict;
8use warnings;
9
10sub new {
11    my ($class , %options) = @_;
12    my $self = {
13        '_default' => 'Title',
14        %options,
15    };
16
17    push @{$self->{_options}}, 'Availability';
18    push @{$self->{_options}}, 'BrowseNode';
19    push @{$self->{_options}}, 'DeliveryMethod';
20    push @{$self->{_options}}, 'Keywords';
21    push @{$self->{_options}}, 'MerchantId';
22    push @{$self->{_options}}, 'Sort';
23    push @{$self->{_options}}, 'Title';
24
25    bless $self, $class;
26}
27
28sub user_or_default {
29    my ($self, $user) = @_;
30    if (defined $user && length($user) > 0) {
31        return $self->find_match($user);
32    }
33    return $self->default();
34}
35
36sub default {
37    my ($self) = @_;
38    return $self->{_default};
39}
40
41sub find_match {
42    my ($self, $value) = @_;
43    for (@{$self->{_options}}) {
44        return $_ if lc($_) eq lc($value);
45    }
46    die "$value is not a valid value for uk::Jewelry!\n";
47}
48
491;
50
51__END__
52
53=head1 NAME
54
55Net::Amazon::Validate::ItemSearch::uk::Jewelry - valid search indicies
56for the uk locale and the Jewelry SearchIndex.
57
58=head1 DESCRIPTION
59
60The default value is Title, unless mode is specified.
61
62The list of available values are:
63
64    Availability
65    BrowseNode
66    DeliveryMethod
67    Keywords
68    MerchantId
69    Sort
70    Title
71
72=cut
73