-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Kiss-Budai Matyas
committed
Jan 8, 2025
1 parent
d563ce8
commit d371fb6
Showing
35 changed files
with
5,730 additions
and
0 deletions.
There are no files selected for viewing
248 changes: 248 additions & 0 deletions
248
flutter_google_places_sdk_platform_interface/lib/src/types/address_component.freezed.dart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,248 @@ | ||
// coverage:ignore-file | ||
// GENERATED CODE - DO NOT MODIFY BY HAND | ||
// ignore_for_file: type=lint | ||
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark | ||
|
||
part of 'address_component.dart'; | ||
|
||
// ************************************************************************** | ||
// FreezedGenerator | ||
// ************************************************************************** | ||
|
||
T _$identity<T>(T value) => value; | ||
|
||
final _privateConstructorUsedError = UnsupportedError( | ||
'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models'); | ||
|
||
AddressComponent _$AddressComponentFromJson(Map<String, dynamic> json) { | ||
return _AddressComponent.fromJson(json); | ||
} | ||
|
||
/// @nodoc | ||
mixin _$AddressComponent { | ||
/// Name of the address component, e.g. "Sydney". | ||
String get name => throw _privateConstructorUsedError; | ||
|
||
/// Short name of the address component, e.g. "AU". | ||
String get shortName => throw _privateConstructorUsedError; | ||
|
||
/// Types of the AddressComponent | ||
/// | ||
/// For a list of supported types, see [Address Component Types](https://developers.google.com/maps/documentation/geocoding/overview#Types) | ||
List<String> get types => throw _privateConstructorUsedError; | ||
|
||
/// Serializes this AddressComponent to a JSON map. | ||
Map<String, dynamic> toJson() => throw _privateConstructorUsedError; | ||
|
||
/// Create a copy of AddressComponent | ||
/// with the given fields replaced by the non-null parameter values. | ||
@JsonKey(includeFromJson: false, includeToJson: false) | ||
$AddressComponentCopyWith<AddressComponent> get copyWith => | ||
throw _privateConstructorUsedError; | ||
} | ||
|
||
/// @nodoc | ||
abstract class $AddressComponentCopyWith<$Res> { | ||
factory $AddressComponentCopyWith( | ||
AddressComponent value, $Res Function(AddressComponent) then) = | ||
_$AddressComponentCopyWithImpl<$Res, AddressComponent>; | ||
@useResult | ||
$Res call({String name, String shortName, List<String> types}); | ||
} | ||
|
||
/// @nodoc | ||
class _$AddressComponentCopyWithImpl<$Res, $Val extends AddressComponent> | ||
implements $AddressComponentCopyWith<$Res> { | ||
_$AddressComponentCopyWithImpl(this._value, this._then); | ||
|
||
// ignore: unused_field | ||
final $Val _value; | ||
// ignore: unused_field | ||
final $Res Function($Val) _then; | ||
|
||
/// Create a copy of AddressComponent | ||
/// with the given fields replaced by the non-null parameter values. | ||
@pragma('vm:prefer-inline') | ||
@override | ||
$Res call({ | ||
Object? name = null, | ||
Object? shortName = null, | ||
Object? types = null, | ||
}) { | ||
return _then(_value.copyWith( | ||
name: null == name | ||
? _value.name | ||
: name // ignore: cast_nullable_to_non_nullable | ||
as String, | ||
shortName: null == shortName | ||
? _value.shortName | ||
: shortName // ignore: cast_nullable_to_non_nullable | ||
as String, | ||
types: null == types | ||
? _value.types | ||
: types // ignore: cast_nullable_to_non_nullable | ||
as List<String>, | ||
) as $Val); | ||
} | ||
} | ||
|
||
/// @nodoc | ||
abstract class _$$AddressComponentImplCopyWith<$Res> | ||
implements $AddressComponentCopyWith<$Res> { | ||
factory _$$AddressComponentImplCopyWith(_$AddressComponentImpl value, | ||
$Res Function(_$AddressComponentImpl) then) = | ||
__$$AddressComponentImplCopyWithImpl<$Res>; | ||
@override | ||
@useResult | ||
$Res call({String name, String shortName, List<String> types}); | ||
} | ||
|
||
/// @nodoc | ||
class __$$AddressComponentImplCopyWithImpl<$Res> | ||
extends _$AddressComponentCopyWithImpl<$Res, _$AddressComponentImpl> | ||
implements _$$AddressComponentImplCopyWith<$Res> { | ||
__$$AddressComponentImplCopyWithImpl(_$AddressComponentImpl _value, | ||
$Res Function(_$AddressComponentImpl) _then) | ||
: super(_value, _then); | ||
|
||
/// Create a copy of AddressComponent | ||
/// with the given fields replaced by the non-null parameter values. | ||
@pragma('vm:prefer-inline') | ||
@override | ||
$Res call({ | ||
Object? name = null, | ||
Object? shortName = null, | ||
Object? types = null, | ||
}) { | ||
return _then(_$AddressComponentImpl( | ||
name: null == name | ||
? _value.name | ||
: name // ignore: cast_nullable_to_non_nullable | ||
as String, | ||
shortName: null == shortName | ||
? _value.shortName | ||
: shortName // ignore: cast_nullable_to_non_nullable | ||
as String, | ||
types: null == types | ||
? _value._types | ||
: types // ignore: cast_nullable_to_non_nullable | ||
as List<String>, | ||
)); | ||
} | ||
} | ||
|
||
/// @nodoc | ||
@JsonSerializable() | ||
class _$AddressComponentImpl | ||
with DiagnosticableTreeMixin | ||
implements _AddressComponent { | ||
const _$AddressComponentImpl( | ||
{required this.name, | ||
required this.shortName, | ||
required final List<String> types}) | ||
: _types = types; | ||
|
||
factory _$AddressComponentImpl.fromJson(Map<String, dynamic> json) => | ||
_$$AddressComponentImplFromJson(json); | ||
|
||
/// Name of the address component, e.g. "Sydney". | ||
@override | ||
final String name; | ||
|
||
/// Short name of the address component, e.g. "AU". | ||
@override | ||
final String shortName; | ||
|
||
/// Types of the AddressComponent | ||
/// | ||
/// For a list of supported types, see [Address Component Types](https://developers.google.com/maps/documentation/geocoding/overview#Types) | ||
final List<String> _types; | ||
|
||
/// Types of the AddressComponent | ||
/// | ||
/// For a list of supported types, see [Address Component Types](https://developers.google.com/maps/documentation/geocoding/overview#Types) | ||
@override | ||
List<String> get types { | ||
if (_types is EqualUnmodifiableListView) return _types; | ||
// ignore: implicit_dynamic_type | ||
return EqualUnmodifiableListView(_types); | ||
} | ||
|
||
@override | ||
String toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) { | ||
return 'AddressComponent(name: $name, shortName: $shortName, types: $types)'; | ||
} | ||
|
||
@override | ||
void debugFillProperties(DiagnosticPropertiesBuilder properties) { | ||
super.debugFillProperties(properties); | ||
properties | ||
..add(DiagnosticsProperty('type', 'AddressComponent')) | ||
..add(DiagnosticsProperty('name', name)) | ||
..add(DiagnosticsProperty('shortName', shortName)) | ||
..add(DiagnosticsProperty('types', types)); | ||
} | ||
|
||
@override | ||
bool operator ==(Object other) { | ||
return identical(this, other) || | ||
(other.runtimeType == runtimeType && | ||
other is _$AddressComponentImpl && | ||
(identical(other.name, name) || other.name == name) && | ||
(identical(other.shortName, shortName) || | ||
other.shortName == shortName) && | ||
const DeepCollectionEquality().equals(other._types, _types)); | ||
} | ||
|
||
@JsonKey(includeFromJson: false, includeToJson: false) | ||
@override | ||
int get hashCode => Object.hash(runtimeType, name, shortName, | ||
const DeepCollectionEquality().hash(_types)); | ||
|
||
/// Create a copy of AddressComponent | ||
/// with the given fields replaced by the non-null parameter values. | ||
@JsonKey(includeFromJson: false, includeToJson: false) | ||
@override | ||
@pragma('vm:prefer-inline') | ||
_$$AddressComponentImplCopyWith<_$AddressComponentImpl> get copyWith => | ||
__$$AddressComponentImplCopyWithImpl<_$AddressComponentImpl>( | ||
this, _$identity); | ||
|
||
@override | ||
Map<String, dynamic> toJson() { | ||
return _$$AddressComponentImplToJson( | ||
this, | ||
); | ||
} | ||
} | ||
|
||
abstract class _AddressComponent implements AddressComponent { | ||
const factory _AddressComponent( | ||
{required final String name, | ||
required final String shortName, | ||
required final List<String> types}) = _$AddressComponentImpl; | ||
|
||
factory _AddressComponent.fromJson(Map<String, dynamic> json) = | ||
_$AddressComponentImpl.fromJson; | ||
|
||
/// Name of the address component, e.g. "Sydney". | ||
@override | ||
String get name; | ||
|
||
/// Short name of the address component, e.g. "AU". | ||
@override | ||
String get shortName; | ||
|
||
/// Types of the AddressComponent | ||
/// | ||
/// For a list of supported types, see [Address Component Types](https://developers.google.com/maps/documentation/geocoding/overview#Types) | ||
@override | ||
List<String> get types; | ||
|
||
/// Create a copy of AddressComponent | ||
/// with the given fields replaced by the non-null parameter values. | ||
@override | ||
@JsonKey(includeFromJson: false, includeToJson: false) | ||
_$$AddressComponentImplCopyWith<_$AddressComponentImpl> get copyWith => | ||
throw _privateConstructorUsedError; | ||
} |
22 changes: 22 additions & 0 deletions
22
flutter_google_places_sdk_platform_interface/lib/src/types/address_component.g.dart
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.