mirror of
https://github.com/pd4d10/git-touch.git
synced 2026-04-29 02:52:20 -05:00
chore: remove unused files
This commit is contained in:
@@ -1,31 +0,0 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
/// This allows the `User` class to access private members in
|
||||
/// the generated file. The value for this is *.g.dart, where
|
||||
/// the star denotes the source file name.
|
||||
part 'user.g.dart';
|
||||
|
||||
/// An annotation for the code generator to know that this class needs the
|
||||
/// JSON serialization logic to be generated.
|
||||
@JsonSerializable()
|
||||
class User {
|
||||
User(this.login, this.avatarUrl, this.name, this.publicRepos, this.followers,
|
||||
this.following);
|
||||
|
||||
String login;
|
||||
String avatarUrl;
|
||||
String name;
|
||||
int publicRepos;
|
||||
int followers;
|
||||
int following;
|
||||
|
||||
/// A necessary factory constructor for creating a new User instance
|
||||
/// from a map. Pass the map to the generated `_$UserFromJson()` constructor.
|
||||
/// The constructor is named after the source class, in this case User.
|
||||
factory User.fromJson(Map<String, dynamic> json) => _$UserFromJson(json);
|
||||
|
||||
/// `toJson` is the convention for a class to declare support for serialization
|
||||
/// to JSON. The implementation simply calls the private, generated
|
||||
/// helper method `_$UserToJson`.
|
||||
Map<String, dynamic> toJson() => _$UserToJson(this);
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
// GENERATED CODE - DO NOT MODIFY BY HAND
|
||||
|
||||
part of 'user.dart';
|
||||
|
||||
// **************************************************************************
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
User _$UserFromJson(Map<String, dynamic> json) {
|
||||
return User(
|
||||
json['login'] as String,
|
||||
json['avatarUrl'] as String,
|
||||
json['name'] as String,
|
||||
json['publicRepos'] as int,
|
||||
json['followers'] as int,
|
||||
json['following'] as int);
|
||||
}
|
||||
|
||||
Map<String, dynamic> _$UserToJson(User instance) => <String, dynamic>{
|
||||
'login': instance.login,
|
||||
'avatarUrl': instance.avatarUrl,
|
||||
'name': instance.name,
|
||||
'publicRepos': instance.publicRepos,
|
||||
'followers': instance.followers,
|
||||
'following': instance.following
|
||||
};
|
||||
Reference in New Issue
Block a user