| .. | .. |
|---|
| 2 | 2 | final String host; |
|---|
| 3 | 3 | final int port; |
|---|
| 4 | 4 | final String? localHost; |
|---|
| 5 | + final String? vpnHost; |
|---|
| 5 | 6 | final String? macAddress; |
|---|
| 6 | 7 | final String? mqttToken; |
|---|
| 7 | 8 | |
|---|
| .. | .. |
|---|
| 9 | 10 | required this.host, |
|---|
| 10 | 11 | this.port = 8765, |
|---|
| 11 | 12 | this.localHost, |
|---|
| 13 | + this.vpnHost, |
|---|
| 12 | 14 | this.macAddress, |
|---|
| 13 | 15 | this.mqttToken, |
|---|
| 14 | 16 | }); |
|---|
| .. | .. |
|---|
| 18 | 20 | 'host': host, |
|---|
| 19 | 21 | 'port': port, |
|---|
| 20 | 22 | if (localHost != null) 'localHost': localHost, |
|---|
| 23 | + if (vpnHost != null) 'vpnHost': vpnHost, |
|---|
| 21 | 24 | if (macAddress != null) 'macAddress': macAddress, |
|---|
| 22 | 25 | if (mqttToken != null) 'mqttToken': mqttToken, |
|---|
| 23 | 26 | }; |
|---|
| .. | .. |
|---|
| 28 | 31 | host: json['host'] as String? ?? '', |
|---|
| 29 | 32 | port: json['port'] as int? ?? 8765, |
|---|
| 30 | 33 | localHost: json['localHost'] as String?, |
|---|
| 34 | + vpnHost: json['vpnHost'] as String?, |
|---|
| 31 | 35 | macAddress: json['macAddress'] as String?, |
|---|
| 32 | 36 | mqttToken: json['mqttToken'] as String?, |
|---|
| 33 | 37 | ); |
|---|
| .. | .. |
|---|
| 37 | 41 | String? host, |
|---|
| 38 | 42 | int? port, |
|---|
| 39 | 43 | String? localHost, |
|---|
| 44 | + String? vpnHost, |
|---|
| 40 | 45 | String? macAddress, |
|---|
| 41 | 46 | String? mqttToken, |
|---|
| 42 | 47 | }) { |
|---|
| .. | .. |
|---|
| 44 | 49 | host: host ?? this.host, |
|---|
| 45 | 50 | port: port ?? this.port, |
|---|
| 46 | 51 | localHost: localHost ?? this.localHost, |
|---|
| 52 | + vpnHost: vpnHost ?? this.vpnHost, |
|---|
| 47 | 53 | macAddress: macAddress ?? this.macAddress, |
|---|
| 48 | 54 | mqttToken: mqttToken ?? this.mqttToken, |
|---|
| 49 | 55 | ); |
|---|