Skip to content

Commit 434ac66

Browse files
committed
fixup - [FEATURE] Implement UseGroupsConfiguration class (kitodo#1422)
1 parent 3aeab17 commit 434ac66

File tree

5 files changed

+41
-15
lines changed

5 files changed

+41
-15
lines changed

Classes/Configuration/UseGroupsConfiguration.php

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ private function __construct()
5656
'useGroupsDownload',
5757
'useGroupsFulltext',
5858
'useGroupsAudio',
59-
'useGroupsScore'
59+
'useGroupsScore',
60+
'useGroupsVideo',
61+
'useGroupsWaveform'
6062
];
6163

6264
foreach ($configKeys as $key) {
@@ -154,6 +156,30 @@ public function getThumbnail(): array
154156
return $this->getByType('Thumbnail');
155157
}
156158

159+
/**
160+
* Get the configuration for 'Video' use groups type.
161+
*
162+
* @access public
163+
*
164+
* @return array
165+
*/
166+
public function getVideo(): array
167+
{
168+
return $this->getByType('Video');
169+
}
170+
171+
/**
172+
* Get the configuration for 'Waveform' use groups type.
173+
*
174+
* @access public
175+
*
176+
* @return array
177+
*/
178+
public function getWaveform(): array
179+
{
180+
return $this->getByType('Waveform');
181+
}
182+
157183
/**
158184
* Get the configuration for use groups.
159185
*
@@ -171,7 +197,7 @@ public function get(): array
171197
*
172198
* @access private
173199
*
174-
* @param string $useType possible values: 'Audio', 'Download', 'Fulltext', 'Image', 'Score', 'Thumbnail'
200+
* @param string $useType possible values: 'Audio', 'Download', 'Fulltext', 'Image', 'Score', 'Thumbnail', 'Video', 'Waveform'
175201
*
176202
* @return array
177203
*/

Documentation/Features/MediaPlayer/METS.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Fractional timecodes (e.g., ``00:06:04.5``) may be used.
2323
Waveform
2424
========
2525

26-
To link preprocessed audio waveform data, use the ``WAVEFORM`` file group (configurable in ``fileGrpWaveform``).
26+
To link preprocessed audio waveform data, use the ``WAVEFORM`` use groups (configurable in ``useGroupsWaveform``).
2727
See :ref:`the section on the waveform component <audiowaveform>` for information on how to generate the data.
2828

2929
.. code-block:: xml

Documentation/Plugins/Index.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ In this example, you place the customized fluid template into this file::
5454
Audioplayer
5555
-----------
5656

57-
The audioplayer plugin is only active if the selected document has a valid audio filegroup (fileGrpAudio).
57+
The audioplayer plugin is only active if the selected document has valid audio file use groups (useGroupsAudio).
5858

5959
Properties
6060
^^^^^^^^^^
@@ -460,7 +460,7 @@ List View
460460
Media Player
461461
------------
462462

463-
The mediaplayer plugin is only active if the selected document has a valid video filegroup (fileGrpVideo).
463+
The mediaplayer plugin is only active if the selected document has valid video file use groups (useGroupsVideo).
464464

465465
:typoscript:`plugin.tx_dlf_mediaplayer.`
466466

Resources/Private/Language/de.locallang_labels.xlf

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -705,13 +705,13 @@
705705
<target>Audio Datei Nutzungsgruppen: Komma-getrennte Liste der @USE Attributwerte der Audiodateien nach absteigender Priorität sortiert (Standard ist "AUDIO")</target>
706706
<source>Audio file use groups: comma-separated list of @USE attribute values ordered by decreasing priority (default is "AUDIO")</source>
707707
</trans-unit>
708-
<trans-unit id="config.files.fileGrpVideo">
709-
<target>Video fileGrp: Komma-getrennte Liste der @USE Attributwerte der Videodateien nach absteigender Priorität sortiert (Standard ist "VIDEO,DEFAULT")</target>
710-
<source>Video fileGrp: comma-separated list of @USE attribute values ordered by decreasing priority (default is "VIDEO,DEFAULT")</source>
708+
<trans-unit id="config.files.useGroupsVideo">
709+
<target>Video Datei Nutzungsgruppen: Komma-getrennte Liste der @USE Attributwerte der Videodateien nach absteigender Priorität sortiert (Standard ist "VIDEO,DEFAULT")</target>
710+
<source>Video file use groups: comma-separated list of @USE attribute values ordered by decreasing priority (default is "VIDEO,DEFAULT")</source>
711711
</trans-unit>
712-
<trans-unit id="config.files.fileGrpWaveform">
713-
<target>Waveform fileGrp: Komma-getrennte Liste der @USE Attributwerte der Waveform-Daten nach absteigender Priorität sortiert (Standard ist "WAVEFORM")</target>
714-
<source>Waveform fileGrp: comma-separated list of @USE attribute values ordered by decreasing priority (default is "WAVEFORM")</source>
712+
<trans-unit id="config.files.useGroupsWaveform">
713+
<target>Waveform Datei Nutzungsgruppen: Komma-getrennte Liste der @USE Attributwerte der Waveform-Daten nach absteigender Priorität sortiert (Standard ist "WAVEFORM")</target>
714+
<source>Waveform file use groups: comma-separated list of @USE attribute values ordered by decreasing priority (default is "WAVEFORM")</source>
715715
</trans-unit>
716716
<trans-unit id="config.iiif.indexAnnotations">
717717
<target>IIIF-Annotationen mit Motivation "painting" als Volltext behandeln?: Als Volltext behandelte Annotationen werden im Suchid idiert (Standard ist "FALSE")</target>

Resources/Private/Language/locallang_labels.xlf

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -530,11 +530,11 @@
530530
<trans-unit id="config.files.useGroupsAudio">
531531
<source>Audio file use groups: comma-separated list of @USE attribute values ordered by decreasing priority (default is "AUDIO")</source>
532532
</trans-unit>
533-
<trans-unit id="config.files.fileGrpVideo">
534-
<source>Video fileGrp: comma-separated list of @USE attribute values ordered by decreasing priority (default is "VIDEO,DEFAULT")</source>
533+
<trans-unit id="config.files.useGroupsVideo">
534+
<source>Video file use groups: comma-separated list of @USE attribute values ordered by decreasing priority (default is "VIDEO,DEFAULT")</source>
535535
</trans-unit>
536-
<trans-unit id="config.files.fileGrpWaveform">
537-
<source>Waveform fileGrp: comma-separated list of @USE attribute values ordered by decreasing priority (default is "WAVEFORM")</source>
536+
<trans-unit id="config.files.useGroupsWaveform">
537+
<source>Waveform file use groups: comma-separated list of @USE attribute values ordered by decreasing priority (default is "WAVEFORM")</source>
538538
</trans-unit>
539539
<trans-unit id="config.iiif.indexAnnotations">
540540
<source>Handle IIIF annotations with motivation "painting" as fulltext?: Handling annotations as fulltexts means they are ided (default is "FALSE")</source>

0 commit comments

Comments
 (0)