Service factory ¶
pems_data.ServiceFactory
¶
A factory class to create and configure various services.
Shared dependencies are created once during initialization.
Source code in pems_data/__init__.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
|
cache
property
¶
Returns:
Name | Type | Description |
---|---|---|
value |
Cache
|
The shared Cache instance managed by this factory. |
caching_s3_source
property
¶
Returns:
Name | Type | Description |
---|---|---|
value |
CachingDataSource
|
The shared CachingDataSource instance managed by this factory. |
s3_source
property
¶
Returns:
Name | Type | Description |
---|---|---|
value |
S3DataSource
|
The shared S3DataSource instance managed by this factory. |
__init__()
¶
Initializes a new ServiceFactory and shared dependencies.
Source code in pems_data/__init__.py
38 39 40 41 42 |
|
stations_service()
¶
Creates a fully-configured StationsService.
Returns:
Name | Type | Description |
---|---|---|
value |
StationsService
|
A StationsService instance configured by the factory. |
Source code in pems_data/__init__.py
44 45 46 47 48 49 50 |
|