Class: IIIFManifest::V3::ManifestServiceLocator

Inherits:
ManifestServiceLocator show all
Defined in:
lib/iiif_manifest/v3/manifest_service_locator.rb

Class Method Summary collapse

Methods inherited from ManifestServiceLocator

child_manifest_builder, child_manifest_builder_factory, collection_manifest_builder, composite_builder, composite_builder_factory, deep_canvas_builder_factory, iiif_resource_factory, image_builder, manifest_builder, resource_builder_factory, sammelband_manifest_builder, sammelband_manifest_builders

Class Method Details

.annotation_content_builderObject



92
93
94
95
96
97
98
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 92

def annotation_content_builder
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::AnnotationContentBuilder,
    iiif_annotation_factory: iiif_annotation_factory,
    body_builder_factory: body_builder_factory
  )
end

.body_builder_factoryObject



100
101
102
103
104
105
106
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 100

def body_builder_factory
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::BodyBuilder,
    iiif_body_factory: iiif_body_factory,
    image_service_builder_factory: image_service_builder_factory
  )
end

.canvas_builderObject



53
54
55
56
57
58
59
60
61
62
63
64
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 53

def canvas_builder
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::CanvasBuilder,
    iiif_canvas_factory: iiif_canvas_factory,
    content_builder: content_builder,
    choice_builder: choice_builder,
    annotation_content_builder: annotation_content_builder,
    iiif_annotation_page_factory: iiif_annotation_page_factory,
    thumbnail_builder_factory: thumbnail_builder_factory,
    placeholder_canvas_builder_factory: placeholder_canvas_builder_factory
  )
end

.canvas_builder_factoryObject



46
47
48
49
50
51
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 46

def canvas_builder_factory
  IIIFManifest::ManifestBuilder::CanvasBuilderFactory.new(
    composite_builder: composite_builder,
    canvas_builder_factory: canvas_builder
  )
end

.choice_builderObject



83
84
85
86
87
88
89
90
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 83

def choice_builder
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::ChoiceBuilder,
    iiif_annotation_factory: iiif_annotation_factory,
    body_builder_factory: body_builder_factory,
    iiif_choice_factory: iiif_choice_factory
  )
end

.collection_manifest_buildersObject



15
16
17
18
19
20
21
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 15

def collection_manifest_builders
  composite_builder_factory.new(
    record_property_builder,
    child_manifest_builder_factory,
    composite_builder: composite_builder
  )
end

.content_builderObject



75
76
77
78
79
80
81
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 75

def content_builder
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::ContentBuilder,
    iiif_annotation_factory: iiif_annotation_factory,
    body_builder_factory: body_builder_factory
  )
end

.iiif_annotation_factoryObject



147
148
149
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 147

def iiif_annotation_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Annotation
end

.iiif_annotation_page_factoryObject



151
152
153
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 151

def iiif_annotation_page_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::AnnotationPage
end

.iiif_autocomplete_service_factoryObject



175
176
177
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 175

def iiif_autocomplete_service_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::AutocompleteService
end

.iiif_body_factoryObject



139
140
141
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 139

def iiif_body_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Body
end

.iiif_canvas_factoryObject



159
160
161
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 159

def iiif_canvas_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Canvas
end

.iiif_choice_factoryObject



143
144
145
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 143

def iiif_choice_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Choice
end

.iiif_collection_factoryObject



23
24
25
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 23

def iiif_collection_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Collection
end

.iiif_manifest_factoryObject



155
156
157
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 155

def iiif_manifest_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest
end

.iiif_placeholder_canvas_factoryObject



163
164
165
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 163

def iiif_placeholder_canvas_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Canvas
end

.iiif_range_factoryObject



167
168
169
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 167

def iiif_range_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Range
end

.iiif_search_service_factoryObject



171
172
173
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 171

def iiif_search_service_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::SearchService
end

.iiif_service_factoryObject



135
136
137
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 135

def iiif_service_factory
  IIIFManifest::V3::ManifestBuilder::IIIFService
end

.iiif_thumbnail_factoryObject



179
180
181
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 179

def iiif_thumbnail_factory
  IIIFManifest::V3::ManifestBuilder::IIIFManifest::Thumbnail
end

.image_service_builder_factoryObject



116
117
118
119
120
121
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 116

def image_service_builder_factory
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::ImageServiceBuilder,
    iiif_service_factory: iiif_service_factory
  )
end

.manifest_buildersObject

Builders which receive a work as an argument to .new and return objects

that respond to #apply.


7
8
9
10
11
12
13
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 7

def manifest_builders
  composite_builder_factory.new(
    record_property_builder,
    structure_builder,
    composite_builder: composite_builder
  )
end

.placeholder_canvas_builder_factoryObject



66
67
68
69
70
71
72
73
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 66

def placeholder_canvas_builder_factory
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::PlaceholderCanvasBuilder,
    iiif_placeholder_canvas_factory: iiif_placeholder_canvas_factory,
    iiif_annotation_page_factory: iiif_annotation_page_factory,
    content_builder: content_builder
  )
end

.record_property_builderObject



27
28
29
30
31
32
33
34
35
36
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 27

def record_property_builder
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::RecordPropertyBuilder,
    iiif_search_service_factory: iiif_search_service_factory,
    iiif_autocomplete_service_factory: iiif_autocomplete_service_factory,
    canvas_builder_factory: deep_canvas_builder_factory,
    thumbnail_builder_factory: thumbnail_builder_factory
    # canvas_builder_factory: canvas_builder_factory
  )
end

.sammelband_sequence_builderObject

Raises:

  • (NotImplementedError)


127
128
129
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 127

def sammelband_sequence_builder
  raise NotImplementedError
end

.sequence_builderObject

Raises:

  • (NotImplementedError)


123
124
125
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 123

def sequence_builder
  raise NotImplementedError
end

.sequence_factoryObject

Raises:

  • (NotImplementedError)


131
132
133
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 131

def sequence_factory
  raise NotImplementedError
end

.structure_builderObject



38
39
40
41
42
43
44
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 38

def structure_builder
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::StructureBuilder,
    canvas_builder_factory: canvas_builder,
    iiif_range_factory: iiif_range_factory
  )
end

.thumbnail_builder_factoryObject



108
109
110
111
112
113
114
# File 'lib/iiif_manifest/v3/manifest_service_locator.rb', line 108

def thumbnail_builder_factory
  IIIFManifest::ManifestServiceLocator::InjectedFactory.new(
    ManifestBuilder::ThumbnailBuilder,
    iiif_thumbnail_factory: iiif_thumbnail_factory,
    image_service_builder_factory: image_service_builder_factory
  )
end