Wikibase
MediaWiki Wikibase extension
Loading...
Searching...
No Matches
Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler Class Reference
+ Inheritance diagram for Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler:
+ Collaboration diagram for Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler:

Public Member Functions

 __construct (GetPropertyLabelWithFallback $useCase, MiddlewareHandler $middlewareHandler, ResponseFactory $responseFactory)
 
 run (... $args)
 
 runUseCase (string $propertyId, string $languageCode)
 
 getParamSettings ()
 
 needsWriteAccess ()
 
 checkPreconditions ()
 Preconditions are checked via PreconditionMiddleware.
 

Static Public Member Functions

static factory ()
 

Private Member Functions

 newSuccessResponse (GetPropertyLabelWithFallbackResponse $useCaseResponse)
 
 newLanguageFallbackResponse (string $propertyId, string $fallbackLanguageCode)
 

Private Attributes

const PROPERTY_ID_PATH_PARAM = 'property_id'
 
const LANGUAGE_CODE_PATH_PARAM = 'language_code'
 
GetPropertyLabelWithFallback $useCase
 
MiddlewareHandler $middlewareHandler
 
ResponseFactory $responseFactory
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::__construct ( GetPropertyLabelWithFallback $useCase,
MiddlewareHandler $middlewareHandler,
ResponseFactory $responseFactory )

Member Function Documentation

◆ checkPreconditions()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::checkPreconditions ( )

Preconditions are checked via PreconditionMiddleware.

◆ factory()

static Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::factory ( )
static

◆ getParamSettings()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::getParamSettings ( )

◆ needsWriteAccess()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::needsWriteAccess ( )

◆ newLanguageFallbackResponse()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::newLanguageFallbackResponse ( string $propertyId,
string $fallbackLanguageCode )
private

◆ newSuccessResponse()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::newSuccessResponse ( GetPropertyLabelWithFallbackResponse $useCaseResponse)
private

◆ run()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::run ( $args)
Parameters
mixed...$args

◆ runUseCase()

Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::runUseCase ( string $propertyId,
string $languageCode )

Member Data Documentation

◆ $middlewareHandler

MiddlewareHandler Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::$middlewareHandler
private

◆ $responseFactory

ResponseFactory Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::$responseFactory
private

◆ $useCase

GetPropertyLabelWithFallback Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::$useCase
private

◆ LANGUAGE_CODE_PATH_PARAM

const Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::LANGUAGE_CODE_PATH_PARAM = 'language_code'
private

◆ PROPERTY_ID_PATH_PARAM

const Wikibase\Repo\RestApi\RouteHandlers\GetPropertyLabelWithFallbackRouteHandler::PROPERTY_ID_PATH_PARAM = 'property_id'
private

The documentation for this class was generated from the following file: