SocketConfigPatterns extension
Adds pattern-matching-related methods to SocketConfig.
- on
Methods
-
map<
TResult extends Object?> (TResult $default(_SocketConfig value)) → TResult -
Available on SocketConfig, provided by the SocketConfigPatterns extension
Aswitch-like method, using callbacks. -
mapOrNull<
TResult extends Object?> (TResult? $default(_SocketConfig value)?) → TResult? -
Available on SocketConfig, provided by the SocketConfigPatterns extension
A variant ofmapthat fallback to returningnull. -
maybeMap<
TResult extends Object?> (TResult $default(_SocketConfig value)?, {required TResult orElse()}) → TResult -
Available on SocketConfig, provided by the SocketConfigPatterns extension
A variant ofmapthat fallback to returningorElse. -
maybeWhen<
TResult extends Object?> (TResult $default(int? mark, Object? tcpFastOpen, TProxyMode? tproxy, bool? acceptProxyProtocol, XrayTargetStrategy? domainStrategy, String? dialerProxy, int? tcpKeepAliveInterval, int? tcpKeepAliveIdle, String? tcpCongestion, int? tcpWindowClamp, int? tcpMaxSeg, bool? penetrate, int? tcpUserTimeout, bool? v6only, String? interfaceName, bool? tcpMptcp, List< CustomSockoptConfig> ? customSockopt, AddressPortStrategy? addressPortStrategy, HappyEyeballsConfig? happyEyeballs, List<String> ? trustedXForwardedFor)?, {required TResult orElse()}) → TResult -
Available on SocketConfig, provided by the SocketConfigPatterns extension
A variant ofwhenthat fallback to anorElsecallback. -
when<
TResult extends Object?> (TResult $default(int? mark, Object? tcpFastOpen, TProxyMode? tproxy, bool? acceptProxyProtocol, XrayTargetStrategy? domainStrategy, String? dialerProxy, int? tcpKeepAliveInterval, int? tcpKeepAliveIdle, String? tcpCongestion, int? tcpWindowClamp, int? tcpMaxSeg, bool? penetrate, int? tcpUserTimeout, bool? v6only, String? interfaceName, bool? tcpMptcp, List< CustomSockoptConfig> ? customSockopt, AddressPortStrategy? addressPortStrategy, HappyEyeballsConfig? happyEyeballs, List<String> ? trustedXForwardedFor)) → TResult -
Available on SocketConfig, provided by the SocketConfigPatterns extension
Aswitch-like method, using callbacks. -
whenOrNull<
TResult extends Object?> (TResult? $default(int? mark, Object? tcpFastOpen, TProxyMode? tproxy, bool? acceptProxyProtocol, XrayTargetStrategy? domainStrategy, String? dialerProxy, int? tcpKeepAliveInterval, int? tcpKeepAliveIdle, String? tcpCongestion, int? tcpWindowClamp, int? tcpMaxSeg, bool? penetrate, int? tcpUserTimeout, bool? v6only, String? interfaceName, bool? tcpMptcp, List< CustomSockoptConfig> ? customSockopt, AddressPortStrategy? addressPortStrategy, HappyEyeballsConfig? happyEyeballs, List<String> ? trustedXForwardedFor)?) → TResult? -
Available on SocketConfig, provided by the SocketConfigPatterns extension
A variant ofwhenthat fallback to returningnull