| 1 | package Google::Api::Auth::Types; | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | use Type::Library -base; | ||
| 7 | use Type::Utils -all; | ||
| 8 | use Types::Standard -types; | ||
| 9 | |||
| 10 | declare 'Authentication', | ||
| 11 | as InstanceOf['Google::Api::Auth::Authentication']; | ||
| 12 | |||
| 13 | coerce 'Authentication', | ||
| 14 | from HashRef, via { 'Google::Api::Auth::Authentication'->new($_) }; | ||
| 15 | |||
| 16 | declare 'RepeatedAuthentication', | ||
| 17 | as ArrayRef[Authentication()]; | ||
| 18 | |||
| 19 | coerce 'RepeatedAuthentication', | ||
| 20 | from ArrayRef[HashRef], via { [ map { 'Google::Api::Auth::Authentication'->new($_) } @$_ ] }; | ||
| 21 | |||
| 22 | declare 'MapStringAuthentication', | ||
| 23 | as HashRef[Authentication()]; | ||
| 24 | |||
| 25 | declare 'AuthenticationRule', | ||
| 26 | as InstanceOf['Google::Api::Auth::AuthenticationRule']; | ||
| 27 | |||
| 28 | coerce 'AuthenticationRule', | ||
| 29 | from HashRef, via { 'Google::Api::Auth::AuthenticationRule'->new($_) }; | ||
| 30 | |||
| 31 | declare 'RepeatedAuthenticationRule', | ||
| 32 | as ArrayRef[AuthenticationRule()]; | ||
| 33 | |||
| 34 | coerce 'RepeatedAuthenticationRule', | ||
| 35 | from ArrayRef[HashRef], via { [ map { 'Google::Api::Auth::AuthenticationRule'->new($_) } @$_ ] }; | ||
| 36 | |||
| 37 | declare 'MapStringAuthenticationRule', | ||
| 38 | as HashRef[AuthenticationRule()]; | ||
| 39 | |||
| 40 | declare 'JwtLocation', | ||
| 41 | as InstanceOf['Google::Api::Auth::JwtLocation']; | ||
| 42 | |||
| 43 | coerce 'JwtLocation', | ||
| 44 | from HashRef, via { 'Google::Api::Auth::JwtLocation'->new($_) }; | ||
| 45 | |||
| 46 | declare 'RepeatedJwtLocation', | ||
| 47 | as ArrayRef[JwtLocation()]; | ||
| 48 | |||
| 49 | coerce 'RepeatedJwtLocation', | ||
| 50 | from ArrayRef[HashRef], via { [ map { 'Google::Api::Auth::JwtLocation'->new($_) } @$_ ] }; | ||
| 51 | |||
| 52 | declare 'MapStringJwtLocation', | ||
| 53 | as HashRef[JwtLocation()]; | ||
| 54 | |||
| 55 | declare 'AuthProvider', | ||
| 56 | as InstanceOf['Google::Api::Auth::AuthProvider']; | ||
| 57 | |||
| 58 | coerce 'AuthProvider', | ||
| 59 | from HashRef, via { 'Google::Api::Auth::AuthProvider'->new($_) }; | ||
| 60 | |||
| 61 | declare 'RepeatedAuthProvider', | ||
| 62 | as ArrayRef[AuthProvider()]; | ||
| 63 | |||
| 64 | coerce 'RepeatedAuthProvider', | ||
| 65 | from ArrayRef[HashRef], via { [ map { 'Google::Api::Auth::AuthProvider'->new($_) } @$_ ] }; | ||
| 66 | |||
| 67 | declare 'MapStringAuthProvider', | ||
| 68 | as HashRef[AuthProvider()]; | ||
| 69 | |||
| 70 | declare 'OAuthRequirements', | ||
| 71 | as InstanceOf['Google::Api::Auth::OAuthRequirements']; | ||
| 72 | |||
| 73 | coerce 'OAuthRequirements', | ||
| 74 | from HashRef, via { 'Google::Api::Auth::OAuthRequirements'->new($_) }; | ||
| 75 | |||
| 76 | declare 'RepeatedOAuthRequirements', | ||
| 77 | as ArrayRef[OAuthRequirements()]; | ||
| 78 | |||
| 79 | coerce 'RepeatedOAuthRequirements', | ||
| 80 | from ArrayRef[HashRef], via { [ map { 'Google::Api::Auth::OAuthRequirements'->new($_) } @$_ ] }; | ||
| 81 | |||
| 82 | declare 'MapStringOAuthRequirements', | ||
| 83 | as HashRef[OAuthRequirements()]; | ||
| 84 | |||
| 85 | declare 'AuthRequirement', | ||
| 86 | as InstanceOf['Google::Api::Auth::AuthRequirement']; | ||
| 87 | |||
| 88 | coerce 'AuthRequirement', | ||
| 89 | from HashRef, via { 'Google::Api::Auth::AuthRequirement'->new($_) }; | ||
| 90 | |||
| 91 | declare 'RepeatedAuthRequirement', | ||
| 92 | as ArrayRef[AuthRequirement()]; | ||
| 93 | |||
| 94 | coerce 'RepeatedAuthRequirement', | ||
| 95 | from ArrayRef[HashRef], via { [ map { 'Google::Api::Auth::AuthRequirement'->new($_) } @$_ ] }; | ||
| 96 | |||
| 97 | declare 'MapStringAuthRequirement', | ||
| 98 | as HashRef[AuthRequirement()]; | ||
| 99 | |||
| 100 | 1; | ||
| 101 | |||
| 102 | __END__ |