| 1 | package Google::Cloud::Discoveryengine::V1::Chunk::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 'Chunk', | ||
| 11 | as InstanceOf['Google::Cloud::Discoveryengine::V1::Chunk::Chunk']; | ||
| 12 | |||
| 13 | coerce 'Chunk', | ||
| 14 | from HashRef, via { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk'->new($_) }; | ||
| 15 | |||
| 16 | declare 'RepeatedChunk', | ||
| 17 | as ArrayRef[Chunk()]; | ||
| 18 | |||
| 19 | coerce 'RepeatedChunk', | ||
| 20 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk'->new($_) } @$_ ] }; | ||
| 21 | |||
| 22 | declare 'MapStringChunk', | ||
| 23 | as HashRef[Chunk()]; | ||
| 24 | |||
| 25 | declare 'StructureType', | ||
| 26 | as (Int | Str); | ||
| 27 | |||
| 28 | declare 'DocumentMetadata', | ||
| 29 | as InstanceOf['Google::Cloud::Discoveryengine::V1::Chunk::Chunk::DocumentMetadata']; | ||
| 30 | |||
| 31 | coerce 'DocumentMetadata', | ||
| 32 | from HashRef, via { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::DocumentMetadata'->new($_) }; | ||
| 33 | |||
| 34 | declare 'RepeatedDocumentMetadata', | ||
| 35 | as ArrayRef[DocumentMetadata()]; | ||
| 36 | |||
| 37 | coerce 'RepeatedDocumentMetadata', | ||
| 38 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::DocumentMetadata'->new($_) } @$_ ] }; | ||
| 39 | |||
| 40 | declare 'MapStringDocumentMetadata', | ||
| 41 | as HashRef[DocumentMetadata()]; | ||
| 42 | |||
| 43 | declare 'PageSpan', | ||
| 44 | as InstanceOf['Google::Cloud::Discoveryengine::V1::Chunk::Chunk::PageSpan']; | ||
| 45 | |||
| 46 | coerce 'PageSpan', | ||
| 47 | from HashRef, via { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::PageSpan'->new($_) }; | ||
| 48 | |||
| 49 | declare 'RepeatedPageSpan', | ||
| 50 | as ArrayRef[PageSpan()]; | ||
| 51 | |||
| 52 | coerce 'RepeatedPageSpan', | ||
| 53 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::PageSpan'->new($_) } @$_ ] }; | ||
| 54 | |||
| 55 | declare 'MapStringPageSpan', | ||
| 56 | as HashRef[PageSpan()]; | ||
| 57 | |||
| 58 | declare 'ChunkMetadata', | ||
| 59 | as InstanceOf['Google::Cloud::Discoveryengine::V1::Chunk::Chunk::ChunkMetadata']; | ||
| 60 | |||
| 61 | coerce 'ChunkMetadata', | ||
| 62 | from HashRef, via { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::ChunkMetadata'->new($_) }; | ||
| 63 | |||
| 64 | declare 'RepeatedChunkMetadata', | ||
| 65 | as ArrayRef[ChunkMetadata()]; | ||
| 66 | |||
| 67 | coerce 'RepeatedChunkMetadata', | ||
| 68 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::ChunkMetadata'->new($_) } @$_ ] }; | ||
| 69 | |||
| 70 | declare 'MapStringChunkMetadata', | ||
| 71 | as HashRef[ChunkMetadata()]; | ||
| 72 | |||
| 73 | declare 'StructuredContent', | ||
| 74 | as InstanceOf['Google::Cloud::Discoveryengine::V1::Chunk::Chunk::StructuredContent']; | ||
| 75 | |||
| 76 | coerce 'StructuredContent', | ||
| 77 | from HashRef, via { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::StructuredContent'->new($_) }; | ||
| 78 | |||
| 79 | declare 'RepeatedStructuredContent', | ||
| 80 | as ArrayRef[StructuredContent()]; | ||
| 81 | |||
| 82 | coerce 'RepeatedStructuredContent', | ||
| 83 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::StructuredContent'->new($_) } @$_ ] }; | ||
| 84 | |||
| 85 | declare 'MapStringStructuredContent', | ||
| 86 | as HashRef[StructuredContent()]; | ||
| 87 | |||
| 88 | declare 'AnnotationMetadata', | ||
| 89 | as InstanceOf['Google::Cloud::Discoveryengine::V1::Chunk::Chunk::AnnotationMetadata']; | ||
| 90 | |||
| 91 | coerce 'AnnotationMetadata', | ||
| 92 | from HashRef, via { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::AnnotationMetadata'->new($_) }; | ||
| 93 | |||
| 94 | declare 'RepeatedAnnotationMetadata', | ||
| 95 | as ArrayRef[AnnotationMetadata()]; | ||
| 96 | |||
| 97 | coerce 'RepeatedAnnotationMetadata', | ||
| 98 | from ArrayRef[HashRef], via { [ map { 'Google::Cloud::Discoveryengine::V1::Chunk::Chunk::AnnotationMetadata'->new($_) } @$_ ] }; | ||
| 99 | |||
| 100 | declare 'MapStringAnnotationMetadata', | ||
| 101 | as HashRef[AnnotationMetadata()]; | ||
| 102 | |||
| 103 | 1; | ||
| 104 | |||
| 105 | __END__ |