ILIAS  trunk Revision v13.0_alpha-62-g3b72d83f2e5
InitHttpServices Class Reference
+ Collaboration diagram for InitHttpServices:

Public Member Functions

 init (Container $container)
 

Detailed Description

Deprecated:
This class is only used for backport compatibility and will be removed in a future release. For most cases this is done by \ILIAS\HTTPinit already. This is needed as long as some other components still rely on old ways of getting the HTTP-service.

Definition at line 43 of file InitHttpServices.php.

Member Function Documentation

◆ init()

InitHttpServices::init ( Container  $container)
Deprecated:

Definition at line 48 of file InitHttpServices.php.

48 : void
49 {
50 $container[RequestFactory::class] = (static fn(Container $c): RequestFactoryImpl => new RequestFactoryImpl(
52 ));
53
54 $container[ResponseFactory::class] = static fn($c): ResponseFactoryImpl => new ResponseFactoryImpl();
55
56 $container[CookieFactory::class] = static fn($c): CookieFactoryImpl => new CookieFactoryImpl();
57
58 $container[MessageFactory::class] = static fn($c): MessageFactoryImpl => new MessageFactoryImpl();
59
60 $container[CookieJarFactory::class] = static fn($c): CookieJarFactoryImpl => new CookieJarFactoryImpl();
61
62 $container[ResponseSenderStrategy::class] = static fn(
63 $c
65
66 $container[DurationFactory::class] = static fn($c): DurationFactory => new DurationFactory(
68 );
69
70 $container['http.security'] = static function ($c): void {
71 throw new OutOfBoundsException('TODO');
72 };
73
74 $container[GlobalHttpState::class] = static fn($c): Services => new Services(
75 $c[RequestFactory::class],
76 $c[ResponseFactory::class],
77 $c[CookieJarFactory::class],
79 $c[DurationFactory::class],
80 $c[CookieFactory::class],
81 $c[MessageFactory::class],
82 );
83 $container['http'] = static fn($c): Services => $c[GlobalHttpState::class];
84 }
Customizing of pimple-DIC for ILIAS.
Definition: Container.php:38
The currently used psr-7 implementation is created and published by guzzle under the MIT license.
Class Services.
Definition: Services.php:43
Interface GlobalHttpState.
Creates psr-7 messages without binding components to the underlying library.
$container
@noRector
Definition: wac.php:39

References Vendor\Package\$c, and $container.


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