NetworkConfig class

Network-related configuration for external metadata enrichment.

Annotations
  • @immutable

Constructors

NetworkConfig({required bool enabled, required bool offline, required int timeoutSeconds, required bool useCache, required int cacheTtlHours, required String githubTokenEnv})
Creates a network configuration.
const
NetworkConfig.defaults()
Returns the default network configuration.
factory

Properties

cacheTtlHours int
The cache time-to-live in hours.
final
enabled bool
Whether online enrichment is enabled.
final
githubTokenEnv String
The environment variable that stores the GitHub token.
final
hashCode int
The hash code for this object.
no setterinherited
offline bool
Whether all network access should be disabled.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
timeoutSeconds int
The per-request timeout in seconds.
final
useCache bool
Whether response caching is enabled.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, Object?>
Serializes the network configuration.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited