diff --git a/src/MDObjectSyndicationSet.php b/src/MDObjectSyndicationSet.php index f3ae1d2..ea74cdd 100644 --- a/src/MDObjectSyndicationSet.php +++ b/src/MDObjectSyndicationSet.php @@ -39,7 +39,7 @@ final class MDObjectSyndicationSet extends MDValueSet { * * @return string */ - public function getSearchUrlForObject(string $repo, string $instId, string $search_value):string { + public static function getSearchUrlForObject(string $repo, string $instId, string $search_value):string { switch ($repo) { case 'ddb': @@ -50,6 +50,22 @@ final class MDObjectSyndicationSet extends MDValueSet { } + /** + * Function for checking the availability of a provided repository in the + * list of known repositories. + * + * @param string $repo Repository name to check. + * + * @return string|boolean + */ + final public static function checkRepositoryIsKnown(string $repo) { + if (isset(self::REPOSITORIES[$repo])) { + return self::REPOSITORIES[$repo]; + } + return false; + + } + /** * Gets a sorted list of the entries in a translated version. *