36 lines
826 B
PHP
36 lines
826 B
PHP
<?PHP
|
|
/**
|
|
* Constains lists for grouping object forms / shapes.
|
|
*
|
|
* @author Joshua Ramon Enslin <joshua@museum-digital.de>
|
|
*/
|
|
declare(strict_types = 1);
|
|
|
|
/**
|
|
* Constains lists for grouping object forms / shapes.
|
|
*/
|
|
final class MDConcObjectForms implements MDImporterConcordanceListInterface {
|
|
|
|
private const FORMS_LIST = [
|
|
'Würfel' => 'cube',
|
|
'Zylinder' => 'cylinder',
|
|
];
|
|
|
|
/**
|
|
* Require a function for getting the concordance target.
|
|
*
|
|
* @param string $input Input string.
|
|
*
|
|
* @return string
|
|
*/
|
|
public static function getConcordanceTarget(string $input):string {
|
|
|
|
if (!isset(self::FORMS_LIST[$input])) {
|
|
throw new MDImporterMissingConcordance("Unknown form type: " . $input);
|
|
}
|
|
|
|
return self::FORMS_LIST[$input];
|
|
|
|
}
|
|
}
|