You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 17, 2023. It is now read-only.
Would like the ability to specify the name to use when computing sealed class. This would remove collisions when creating similarly named classes. See the following example taken from sealed_unions_generator
@Seal('WeatherState')
abstract class WeatherModel {
@Sealed()
void initial();
@Sealed()
void loading();
@Sealed()
void loaded(int temperature);
}
// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'weather_model.dart';
// **************************************************************************
// SealedUnionsGenerator
// **************************************************************************
class WeatherState extends Union3Impl<WeatherStateInitial, WeatherStateLoading,
WeatherStateLoaded> {
static final Triplet<WeatherStateInitial, WeatherStateLoading,
WeatherStateLoaded> _factory =
const Triplet<WeatherStateInitial, WeatherStateLoading,
WeatherStateLoaded>();
WeatherState._(
Union3<WeatherStateInitial, WeatherStateLoading, WeatherStateLoaded>
union)
: super(union);
factory WeatherState.initial() =>
WeatherState._(_factory.first(WeatherStateInitial()));
factory WeatherState.loading() =>
WeatherState._(_factory.second(WeatherStateLoading()));
factory WeatherState.loaded(int temperature) =>
WeatherState._(_factory.third(WeatherStateLoaded(temperature)));
}
class WeatherStateInitial {
WeatherStateInitial();
}
class WeatherStateLoading {
WeatherStateLoading();
}
class WeatherStateLoaded {
final int temperature;
WeatherStateLoaded(this.temperature);
}
The text was updated successfully, but these errors were encountered:
I run into the same problem - is there a ETA for a fix for that. This seemed to be a common problem when you create multiple blocs. I did run into it that problem after just one day by using Start and Stop in multiple bloc's.
Would like the ability to specify the name to use when computing sealed class. This would remove collisions when creating similarly named classes. See the following example taken from sealed_unions_generator
The text was updated successfully, but these errors were encountered: