| 1 | package Google::Firestore::V1::Pipeline::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 'StructuredPipeline', | ||
| 11 | as InstanceOf['Google::Firestore::V1::Pipeline::StructuredPipeline']; | ||
| 12 | |||
| 13 | coerce 'StructuredPipeline', | ||
| 14 | from HashRef, via { 'Google::Firestore::V1::Pipeline::StructuredPipeline'->new($_) }; | ||
| 15 | |||
| 16 | declare 'RepeatedStructuredPipeline', | ||
| 17 | as ArrayRef[StructuredPipeline()]; | ||
| 18 | |||
| 19 | coerce 'RepeatedStructuredPipeline', | ||
| 20 | from ArrayRef[HashRef], via { [ map { 'Google::Firestore::V1::Pipeline::StructuredPipeline'->new($_) } @$_ ] }; | ||
| 21 | |||
| 22 | declare 'MapStringStructuredPipeline', | ||
| 23 | as HashRef[StructuredPipeline()]; | ||
| 24 | |||
| 25 | declare 'OptionsEntry', | ||
| 26 | as InstanceOf['Google::Firestore::V1::Pipeline::StructuredPipeline::OptionsEntry']; | ||
| 27 | |||
| 28 | coerce 'OptionsEntry', | ||
| 29 | from HashRef, via { 'Google::Firestore::V1::Pipeline::StructuredPipeline::OptionsEntry'->new($_) }; | ||
| 30 | |||
| 31 | declare 'RepeatedOptionsEntry', | ||
| 32 | as ArrayRef[OptionsEntry()]; | ||
| 33 | |||
| 34 | coerce 'RepeatedOptionsEntry', | ||
| 35 | from ArrayRef[HashRef], via { [ map { 'Google::Firestore::V1::Pipeline::StructuredPipeline::OptionsEntry'->new($_) } @$_ ] }; | ||
| 36 | |||
| 37 | declare 'MapStringOptionsEntry', | ||
| 38 | as HashRef[OptionsEntry()]; | ||
| 39 | |||
| 40 | 1; | ||
| 41 | |||
| 42 | __END__ |