selfprivacy.org.app/lib/logic/cubit/provider_volumes/provider_volume_state.dart

28 lines
788 B
Dart
Raw Normal View History

2022-08-24 23:45:02 +00:00
part of 'provider_volume_cubit.dart';
class ApiProviderVolumeState extends ServerInstallationDependendState {
2022-09-18 22:11:26 +00:00
const ApiProviderVolumeState(this._volumes, this.status, this.isResizing);
2022-08-24 23:45:02 +00:00
const ApiProviderVolumeState.initial()
2022-09-18 22:11:26 +00:00
: this(const [], LoadingStatus.uninitialized, false);
2022-08-24 23:45:02 +00:00
final List<ServerVolume> _volumes;
final LoadingStatus status;
2022-09-18 22:11:26 +00:00
final bool isResizing;
2022-08-24 23:45:02 +00:00
List<ServerVolume> get volumes => _volumes;
ApiProviderVolumeState copyWith({
final List<ServerVolume>? volumes,
final LoadingStatus? status,
2022-09-18 22:11:26 +00:00
final bool? isResizing,
2022-08-24 23:45:02 +00:00
}) =>
ApiProviderVolumeState(
volumes ?? _volumes,
status ?? this.status,
2022-09-18 22:11:26 +00:00
isResizing ?? this.isResizing,
2022-08-24 23:45:02 +00:00
);
@override
2022-09-18 23:13:25 +00:00
List<Object?> get props => [_volumes, status, isResizing];
2022-08-24 23:45:02 +00:00
}