1536 lines
49 KiB
Dart
1536 lines
49 KiB
Dart
// GENERATED CODE - DO NOT MODIFY BY HAND
|
|
|
|
part of 'app_database.dart';
|
|
|
|
// ignore_for_file: type=lint
|
|
class $UserProfileRowsTable extends UserProfileRows
|
|
with TableInfo<$UserProfileRowsTable, UserProfileRow> {
|
|
@override
|
|
final GeneratedDatabase attachedDatabase;
|
|
final String? _alias;
|
|
$UserProfileRowsTable(this.attachedDatabase, [this._alias]);
|
|
static const VerificationMeta _firebaseUidMeta = const VerificationMeta(
|
|
'firebaseUid',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<String> firebaseUid = GeneratedColumn<String>(
|
|
'firebase_uid',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: true,
|
|
);
|
|
static const VerificationMeta _emailMeta = const VerificationMeta('email');
|
|
@override
|
|
late final GeneratedColumn<String> email = GeneratedColumn<String>(
|
|
'email',
|
|
aliasedName,
|
|
true,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: false,
|
|
);
|
|
static const VerificationMeta _displayNameMeta = const VerificationMeta(
|
|
'displayName',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<String> displayName = GeneratedColumn<String>(
|
|
'display_name',
|
|
aliasedName,
|
|
true,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: false,
|
|
);
|
|
static const VerificationMeta _photoUrlMeta = const VerificationMeta(
|
|
'photoUrl',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<String> photoUrl = GeneratedColumn<String>(
|
|
'photo_url',
|
|
aliasedName,
|
|
true,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: false,
|
|
);
|
|
static const VerificationMeta _localeMeta = const VerificationMeta('locale');
|
|
@override
|
|
late final GeneratedColumn<String> locale = GeneratedColumn<String>(
|
|
'locale',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: false,
|
|
defaultValue: const Constant('en'),
|
|
);
|
|
static const VerificationMeta _timezoneMeta = const VerificationMeta(
|
|
'timezone',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<String> timezone = GeneratedColumn<String>(
|
|
'timezone',
|
|
aliasedName,
|
|
true,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: false,
|
|
);
|
|
static const VerificationMeta _onboardingCompletedMeta =
|
|
const VerificationMeta('onboardingCompleted');
|
|
@override
|
|
late final GeneratedColumn<bool> onboardingCompleted = GeneratedColumn<bool>(
|
|
'onboarding_completed',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.bool,
|
|
requiredDuringInsert: false,
|
|
defaultConstraints: GeneratedColumn.constraintIsAlways(
|
|
'CHECK ("onboarding_completed" IN (0, 1))',
|
|
),
|
|
defaultValue: const Constant(false),
|
|
);
|
|
static const VerificationMeta _revisionMeta = const VerificationMeta(
|
|
'revision',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<int> revision = GeneratedColumn<int>(
|
|
'revision',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.int,
|
|
requiredDuringInsert: false,
|
|
defaultValue: const Constant(1),
|
|
);
|
|
static const VerificationMeta _updatedAtMeta = const VerificationMeta(
|
|
'updatedAt',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<DateTime> updatedAt = GeneratedColumn<DateTime>(
|
|
'updated_at',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.dateTime,
|
|
requiredDuringInsert: true,
|
|
);
|
|
static const VerificationMeta _lastSyncedAtMeta = const VerificationMeta(
|
|
'lastSyncedAt',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<DateTime> lastSyncedAt = GeneratedColumn<DateTime>(
|
|
'last_synced_at',
|
|
aliasedName,
|
|
true,
|
|
type: DriftSqlType.dateTime,
|
|
requiredDuringInsert: false,
|
|
);
|
|
static const VerificationMeta _dirtyMeta = const VerificationMeta('dirty');
|
|
@override
|
|
late final GeneratedColumn<bool> dirty = GeneratedColumn<bool>(
|
|
'dirty',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.bool,
|
|
requiredDuringInsert: false,
|
|
defaultConstraints: GeneratedColumn.constraintIsAlways(
|
|
'CHECK ("dirty" IN (0, 1))',
|
|
),
|
|
defaultValue: const Constant(false),
|
|
);
|
|
@override
|
|
List<GeneratedColumn> get $columns => [
|
|
firebaseUid,
|
|
email,
|
|
displayName,
|
|
photoUrl,
|
|
locale,
|
|
timezone,
|
|
onboardingCompleted,
|
|
revision,
|
|
updatedAt,
|
|
lastSyncedAt,
|
|
dirty,
|
|
];
|
|
@override
|
|
String get aliasedName => _alias ?? actualTableName;
|
|
@override
|
|
String get actualTableName => $name;
|
|
static const String $name = 'user_profile_rows';
|
|
@override
|
|
VerificationContext validateIntegrity(
|
|
Insertable<UserProfileRow> instance, {
|
|
bool isInserting = false,
|
|
}) {
|
|
final context = VerificationContext();
|
|
final data = instance.toColumns(true);
|
|
if (data.containsKey('firebase_uid')) {
|
|
context.handle(
|
|
_firebaseUidMeta,
|
|
firebaseUid.isAcceptableOrUnknown(
|
|
data['firebase_uid']!,
|
|
_firebaseUidMeta,
|
|
),
|
|
);
|
|
} else if (isInserting) {
|
|
context.missing(_firebaseUidMeta);
|
|
}
|
|
if (data.containsKey('email')) {
|
|
context.handle(
|
|
_emailMeta,
|
|
email.isAcceptableOrUnknown(data['email']!, _emailMeta),
|
|
);
|
|
}
|
|
if (data.containsKey('display_name')) {
|
|
context.handle(
|
|
_displayNameMeta,
|
|
displayName.isAcceptableOrUnknown(
|
|
data['display_name']!,
|
|
_displayNameMeta,
|
|
),
|
|
);
|
|
}
|
|
if (data.containsKey('photo_url')) {
|
|
context.handle(
|
|
_photoUrlMeta,
|
|
photoUrl.isAcceptableOrUnknown(data['photo_url']!, _photoUrlMeta),
|
|
);
|
|
}
|
|
if (data.containsKey('locale')) {
|
|
context.handle(
|
|
_localeMeta,
|
|
locale.isAcceptableOrUnknown(data['locale']!, _localeMeta),
|
|
);
|
|
}
|
|
if (data.containsKey('timezone')) {
|
|
context.handle(
|
|
_timezoneMeta,
|
|
timezone.isAcceptableOrUnknown(data['timezone']!, _timezoneMeta),
|
|
);
|
|
}
|
|
if (data.containsKey('onboarding_completed')) {
|
|
context.handle(
|
|
_onboardingCompletedMeta,
|
|
onboardingCompleted.isAcceptableOrUnknown(
|
|
data['onboarding_completed']!,
|
|
_onboardingCompletedMeta,
|
|
),
|
|
);
|
|
}
|
|
if (data.containsKey('revision')) {
|
|
context.handle(
|
|
_revisionMeta,
|
|
revision.isAcceptableOrUnknown(data['revision']!, _revisionMeta),
|
|
);
|
|
}
|
|
if (data.containsKey('updated_at')) {
|
|
context.handle(
|
|
_updatedAtMeta,
|
|
updatedAt.isAcceptableOrUnknown(data['updated_at']!, _updatedAtMeta),
|
|
);
|
|
} else if (isInserting) {
|
|
context.missing(_updatedAtMeta);
|
|
}
|
|
if (data.containsKey('last_synced_at')) {
|
|
context.handle(
|
|
_lastSyncedAtMeta,
|
|
lastSyncedAt.isAcceptableOrUnknown(
|
|
data['last_synced_at']!,
|
|
_lastSyncedAtMeta,
|
|
),
|
|
);
|
|
}
|
|
if (data.containsKey('dirty')) {
|
|
context.handle(
|
|
_dirtyMeta,
|
|
dirty.isAcceptableOrUnknown(data['dirty']!, _dirtyMeta),
|
|
);
|
|
}
|
|
return context;
|
|
}
|
|
|
|
@override
|
|
Set<GeneratedColumn> get $primaryKey => {firebaseUid};
|
|
@override
|
|
UserProfileRow map(Map<String, dynamic> data, {String? tablePrefix}) {
|
|
final effectivePrefix = tablePrefix != null ? '$tablePrefix.' : '';
|
|
return UserProfileRow(
|
|
firebaseUid: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}firebase_uid'],
|
|
)!,
|
|
email: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}email'],
|
|
),
|
|
displayName: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}display_name'],
|
|
),
|
|
photoUrl: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}photo_url'],
|
|
),
|
|
locale: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}locale'],
|
|
)!,
|
|
timezone: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}timezone'],
|
|
),
|
|
onboardingCompleted: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.bool,
|
|
data['${effectivePrefix}onboarding_completed'],
|
|
)!,
|
|
revision: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.int,
|
|
data['${effectivePrefix}revision'],
|
|
)!,
|
|
updatedAt: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.dateTime,
|
|
data['${effectivePrefix}updated_at'],
|
|
)!,
|
|
lastSyncedAt: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.dateTime,
|
|
data['${effectivePrefix}last_synced_at'],
|
|
),
|
|
dirty: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.bool,
|
|
data['${effectivePrefix}dirty'],
|
|
)!,
|
|
);
|
|
}
|
|
|
|
@override
|
|
$UserProfileRowsTable createAlias(String alias) {
|
|
return $UserProfileRowsTable(attachedDatabase, alias);
|
|
}
|
|
}
|
|
|
|
class UserProfileRow extends DataClass implements Insertable<UserProfileRow> {
|
|
final String firebaseUid;
|
|
final String? email;
|
|
final String? displayName;
|
|
final String? photoUrl;
|
|
final String locale;
|
|
final String? timezone;
|
|
final bool onboardingCompleted;
|
|
final int revision;
|
|
final DateTime updatedAt;
|
|
final DateTime? lastSyncedAt;
|
|
final bool dirty;
|
|
const UserProfileRow({
|
|
required this.firebaseUid,
|
|
this.email,
|
|
this.displayName,
|
|
this.photoUrl,
|
|
required this.locale,
|
|
this.timezone,
|
|
required this.onboardingCompleted,
|
|
required this.revision,
|
|
required this.updatedAt,
|
|
this.lastSyncedAt,
|
|
required this.dirty,
|
|
});
|
|
@override
|
|
Map<String, Expression> toColumns(bool nullToAbsent) {
|
|
final map = <String, Expression>{};
|
|
map['firebase_uid'] = Variable<String>(firebaseUid);
|
|
if (!nullToAbsent || email != null) {
|
|
map['email'] = Variable<String>(email);
|
|
}
|
|
if (!nullToAbsent || displayName != null) {
|
|
map['display_name'] = Variable<String>(displayName);
|
|
}
|
|
if (!nullToAbsent || photoUrl != null) {
|
|
map['photo_url'] = Variable<String>(photoUrl);
|
|
}
|
|
map['locale'] = Variable<String>(locale);
|
|
if (!nullToAbsent || timezone != null) {
|
|
map['timezone'] = Variable<String>(timezone);
|
|
}
|
|
map['onboarding_completed'] = Variable<bool>(onboardingCompleted);
|
|
map['revision'] = Variable<int>(revision);
|
|
map['updated_at'] = Variable<DateTime>(updatedAt);
|
|
if (!nullToAbsent || lastSyncedAt != null) {
|
|
map['last_synced_at'] = Variable<DateTime>(lastSyncedAt);
|
|
}
|
|
map['dirty'] = Variable<bool>(dirty);
|
|
return map;
|
|
}
|
|
|
|
UserProfileRowsCompanion toCompanion(bool nullToAbsent) {
|
|
return UserProfileRowsCompanion(
|
|
firebaseUid: Value(firebaseUid),
|
|
email: email == null && nullToAbsent
|
|
? const Value.absent()
|
|
: Value(email),
|
|
displayName: displayName == null && nullToAbsent
|
|
? const Value.absent()
|
|
: Value(displayName),
|
|
photoUrl: photoUrl == null && nullToAbsent
|
|
? const Value.absent()
|
|
: Value(photoUrl),
|
|
locale: Value(locale),
|
|
timezone: timezone == null && nullToAbsent
|
|
? const Value.absent()
|
|
: Value(timezone),
|
|
onboardingCompleted: Value(onboardingCompleted),
|
|
revision: Value(revision),
|
|
updatedAt: Value(updatedAt),
|
|
lastSyncedAt: lastSyncedAt == null && nullToAbsent
|
|
? const Value.absent()
|
|
: Value(lastSyncedAt),
|
|
dirty: Value(dirty),
|
|
);
|
|
}
|
|
|
|
factory UserProfileRow.fromJson(
|
|
Map<String, dynamic> json, {
|
|
ValueSerializer? serializer,
|
|
}) {
|
|
serializer ??= driftRuntimeOptions.defaultSerializer;
|
|
return UserProfileRow(
|
|
firebaseUid: serializer.fromJson<String>(json['firebaseUid']),
|
|
email: serializer.fromJson<String?>(json['email']),
|
|
displayName: serializer.fromJson<String?>(json['displayName']),
|
|
photoUrl: serializer.fromJson<String?>(json['photoUrl']),
|
|
locale: serializer.fromJson<String>(json['locale']),
|
|
timezone: serializer.fromJson<String?>(json['timezone']),
|
|
onboardingCompleted: serializer.fromJson<bool>(
|
|
json['onboardingCompleted'],
|
|
),
|
|
revision: serializer.fromJson<int>(json['revision']),
|
|
updatedAt: serializer.fromJson<DateTime>(json['updatedAt']),
|
|
lastSyncedAt: serializer.fromJson<DateTime?>(json['lastSyncedAt']),
|
|
dirty: serializer.fromJson<bool>(json['dirty']),
|
|
);
|
|
}
|
|
@override
|
|
Map<String, dynamic> toJson({ValueSerializer? serializer}) {
|
|
serializer ??= driftRuntimeOptions.defaultSerializer;
|
|
return <String, dynamic>{
|
|
'firebaseUid': serializer.toJson<String>(firebaseUid),
|
|
'email': serializer.toJson<String?>(email),
|
|
'displayName': serializer.toJson<String?>(displayName),
|
|
'photoUrl': serializer.toJson<String?>(photoUrl),
|
|
'locale': serializer.toJson<String>(locale),
|
|
'timezone': serializer.toJson<String?>(timezone),
|
|
'onboardingCompleted': serializer.toJson<bool>(onboardingCompleted),
|
|
'revision': serializer.toJson<int>(revision),
|
|
'updatedAt': serializer.toJson<DateTime>(updatedAt),
|
|
'lastSyncedAt': serializer.toJson<DateTime?>(lastSyncedAt),
|
|
'dirty': serializer.toJson<bool>(dirty),
|
|
};
|
|
}
|
|
|
|
UserProfileRow copyWith({
|
|
String? firebaseUid,
|
|
Value<String?> email = const Value.absent(),
|
|
Value<String?> displayName = const Value.absent(),
|
|
Value<String?> photoUrl = const Value.absent(),
|
|
String? locale,
|
|
Value<String?> timezone = const Value.absent(),
|
|
bool? onboardingCompleted,
|
|
int? revision,
|
|
DateTime? updatedAt,
|
|
Value<DateTime?> lastSyncedAt = const Value.absent(),
|
|
bool? dirty,
|
|
}) => UserProfileRow(
|
|
firebaseUid: firebaseUid ?? this.firebaseUid,
|
|
email: email.present ? email.value : this.email,
|
|
displayName: displayName.present ? displayName.value : this.displayName,
|
|
photoUrl: photoUrl.present ? photoUrl.value : this.photoUrl,
|
|
locale: locale ?? this.locale,
|
|
timezone: timezone.present ? timezone.value : this.timezone,
|
|
onboardingCompleted: onboardingCompleted ?? this.onboardingCompleted,
|
|
revision: revision ?? this.revision,
|
|
updatedAt: updatedAt ?? this.updatedAt,
|
|
lastSyncedAt: lastSyncedAt.present ? lastSyncedAt.value : this.lastSyncedAt,
|
|
dirty: dirty ?? this.dirty,
|
|
);
|
|
UserProfileRow copyWithCompanion(UserProfileRowsCompanion data) {
|
|
return UserProfileRow(
|
|
firebaseUid: data.firebaseUid.present
|
|
? data.firebaseUid.value
|
|
: this.firebaseUid,
|
|
email: data.email.present ? data.email.value : this.email,
|
|
displayName: data.displayName.present
|
|
? data.displayName.value
|
|
: this.displayName,
|
|
photoUrl: data.photoUrl.present ? data.photoUrl.value : this.photoUrl,
|
|
locale: data.locale.present ? data.locale.value : this.locale,
|
|
timezone: data.timezone.present ? data.timezone.value : this.timezone,
|
|
onboardingCompleted: data.onboardingCompleted.present
|
|
? data.onboardingCompleted.value
|
|
: this.onboardingCompleted,
|
|
revision: data.revision.present ? data.revision.value : this.revision,
|
|
updatedAt: data.updatedAt.present ? data.updatedAt.value : this.updatedAt,
|
|
lastSyncedAt: data.lastSyncedAt.present
|
|
? data.lastSyncedAt.value
|
|
: this.lastSyncedAt,
|
|
dirty: data.dirty.present ? data.dirty.value : this.dirty,
|
|
);
|
|
}
|
|
|
|
@override
|
|
String toString() {
|
|
return (StringBuffer('UserProfileRow(')
|
|
..write('firebaseUid: $firebaseUid, ')
|
|
..write('email: $email, ')
|
|
..write('displayName: $displayName, ')
|
|
..write('photoUrl: $photoUrl, ')
|
|
..write('locale: $locale, ')
|
|
..write('timezone: $timezone, ')
|
|
..write('onboardingCompleted: $onboardingCompleted, ')
|
|
..write('revision: $revision, ')
|
|
..write('updatedAt: $updatedAt, ')
|
|
..write('lastSyncedAt: $lastSyncedAt, ')
|
|
..write('dirty: $dirty')
|
|
..write(')'))
|
|
.toString();
|
|
}
|
|
|
|
@override
|
|
int get hashCode => Object.hash(
|
|
firebaseUid,
|
|
email,
|
|
displayName,
|
|
photoUrl,
|
|
locale,
|
|
timezone,
|
|
onboardingCompleted,
|
|
revision,
|
|
updatedAt,
|
|
lastSyncedAt,
|
|
dirty,
|
|
);
|
|
@override
|
|
bool operator ==(Object other) =>
|
|
identical(this, other) ||
|
|
(other is UserProfileRow &&
|
|
other.firebaseUid == this.firebaseUid &&
|
|
other.email == this.email &&
|
|
other.displayName == this.displayName &&
|
|
other.photoUrl == this.photoUrl &&
|
|
other.locale == this.locale &&
|
|
other.timezone == this.timezone &&
|
|
other.onboardingCompleted == this.onboardingCompleted &&
|
|
other.revision == this.revision &&
|
|
other.updatedAt == this.updatedAt &&
|
|
other.lastSyncedAt == this.lastSyncedAt &&
|
|
other.dirty == this.dirty);
|
|
}
|
|
|
|
class UserProfileRowsCompanion extends UpdateCompanion<UserProfileRow> {
|
|
final Value<String> firebaseUid;
|
|
final Value<String?> email;
|
|
final Value<String?> displayName;
|
|
final Value<String?> photoUrl;
|
|
final Value<String> locale;
|
|
final Value<String?> timezone;
|
|
final Value<bool> onboardingCompleted;
|
|
final Value<int> revision;
|
|
final Value<DateTime> updatedAt;
|
|
final Value<DateTime?> lastSyncedAt;
|
|
final Value<bool> dirty;
|
|
final Value<int> rowid;
|
|
const UserProfileRowsCompanion({
|
|
this.firebaseUid = const Value.absent(),
|
|
this.email = const Value.absent(),
|
|
this.displayName = const Value.absent(),
|
|
this.photoUrl = const Value.absent(),
|
|
this.locale = const Value.absent(),
|
|
this.timezone = const Value.absent(),
|
|
this.onboardingCompleted = const Value.absent(),
|
|
this.revision = const Value.absent(),
|
|
this.updatedAt = const Value.absent(),
|
|
this.lastSyncedAt = const Value.absent(),
|
|
this.dirty = const Value.absent(),
|
|
this.rowid = const Value.absent(),
|
|
});
|
|
UserProfileRowsCompanion.insert({
|
|
required String firebaseUid,
|
|
this.email = const Value.absent(),
|
|
this.displayName = const Value.absent(),
|
|
this.photoUrl = const Value.absent(),
|
|
this.locale = const Value.absent(),
|
|
this.timezone = const Value.absent(),
|
|
this.onboardingCompleted = const Value.absent(),
|
|
this.revision = const Value.absent(),
|
|
required DateTime updatedAt,
|
|
this.lastSyncedAt = const Value.absent(),
|
|
this.dirty = const Value.absent(),
|
|
this.rowid = const Value.absent(),
|
|
}) : firebaseUid = Value(firebaseUid),
|
|
updatedAt = Value(updatedAt);
|
|
static Insertable<UserProfileRow> custom({
|
|
Expression<String>? firebaseUid,
|
|
Expression<String>? email,
|
|
Expression<String>? displayName,
|
|
Expression<String>? photoUrl,
|
|
Expression<String>? locale,
|
|
Expression<String>? timezone,
|
|
Expression<bool>? onboardingCompleted,
|
|
Expression<int>? revision,
|
|
Expression<DateTime>? updatedAt,
|
|
Expression<DateTime>? lastSyncedAt,
|
|
Expression<bool>? dirty,
|
|
Expression<int>? rowid,
|
|
}) {
|
|
return RawValuesInsertable({
|
|
if (firebaseUid != null) 'firebase_uid': firebaseUid,
|
|
if (email != null) 'email': email,
|
|
if (displayName != null) 'display_name': displayName,
|
|
if (photoUrl != null) 'photo_url': photoUrl,
|
|
if (locale != null) 'locale': locale,
|
|
if (timezone != null) 'timezone': timezone,
|
|
if (onboardingCompleted != null)
|
|
'onboarding_completed': onboardingCompleted,
|
|
if (revision != null) 'revision': revision,
|
|
if (updatedAt != null) 'updated_at': updatedAt,
|
|
if (lastSyncedAt != null) 'last_synced_at': lastSyncedAt,
|
|
if (dirty != null) 'dirty': dirty,
|
|
if (rowid != null) 'rowid': rowid,
|
|
});
|
|
}
|
|
|
|
UserProfileRowsCompanion copyWith({
|
|
Value<String>? firebaseUid,
|
|
Value<String?>? email,
|
|
Value<String?>? displayName,
|
|
Value<String?>? photoUrl,
|
|
Value<String>? locale,
|
|
Value<String?>? timezone,
|
|
Value<bool>? onboardingCompleted,
|
|
Value<int>? revision,
|
|
Value<DateTime>? updatedAt,
|
|
Value<DateTime?>? lastSyncedAt,
|
|
Value<bool>? dirty,
|
|
Value<int>? rowid,
|
|
}) {
|
|
return UserProfileRowsCompanion(
|
|
firebaseUid: firebaseUid ?? this.firebaseUid,
|
|
email: email ?? this.email,
|
|
displayName: displayName ?? this.displayName,
|
|
photoUrl: photoUrl ?? this.photoUrl,
|
|
locale: locale ?? this.locale,
|
|
timezone: timezone ?? this.timezone,
|
|
onboardingCompleted: onboardingCompleted ?? this.onboardingCompleted,
|
|
revision: revision ?? this.revision,
|
|
updatedAt: updatedAt ?? this.updatedAt,
|
|
lastSyncedAt: lastSyncedAt ?? this.lastSyncedAt,
|
|
dirty: dirty ?? this.dirty,
|
|
rowid: rowid ?? this.rowid,
|
|
);
|
|
}
|
|
|
|
@override
|
|
Map<String, Expression> toColumns(bool nullToAbsent) {
|
|
final map = <String, Expression>{};
|
|
if (firebaseUid.present) {
|
|
map['firebase_uid'] = Variable<String>(firebaseUid.value);
|
|
}
|
|
if (email.present) {
|
|
map['email'] = Variable<String>(email.value);
|
|
}
|
|
if (displayName.present) {
|
|
map['display_name'] = Variable<String>(displayName.value);
|
|
}
|
|
if (photoUrl.present) {
|
|
map['photo_url'] = Variable<String>(photoUrl.value);
|
|
}
|
|
if (locale.present) {
|
|
map['locale'] = Variable<String>(locale.value);
|
|
}
|
|
if (timezone.present) {
|
|
map['timezone'] = Variable<String>(timezone.value);
|
|
}
|
|
if (onboardingCompleted.present) {
|
|
map['onboarding_completed'] = Variable<bool>(onboardingCompleted.value);
|
|
}
|
|
if (revision.present) {
|
|
map['revision'] = Variable<int>(revision.value);
|
|
}
|
|
if (updatedAt.present) {
|
|
map['updated_at'] = Variable<DateTime>(updatedAt.value);
|
|
}
|
|
if (lastSyncedAt.present) {
|
|
map['last_synced_at'] = Variable<DateTime>(lastSyncedAt.value);
|
|
}
|
|
if (dirty.present) {
|
|
map['dirty'] = Variable<bool>(dirty.value);
|
|
}
|
|
if (rowid.present) {
|
|
map['rowid'] = Variable<int>(rowid.value);
|
|
}
|
|
return map;
|
|
}
|
|
|
|
@override
|
|
String toString() {
|
|
return (StringBuffer('UserProfileRowsCompanion(')
|
|
..write('firebaseUid: $firebaseUid, ')
|
|
..write('email: $email, ')
|
|
..write('displayName: $displayName, ')
|
|
..write('photoUrl: $photoUrl, ')
|
|
..write('locale: $locale, ')
|
|
..write('timezone: $timezone, ')
|
|
..write('onboardingCompleted: $onboardingCompleted, ')
|
|
..write('revision: $revision, ')
|
|
..write('updatedAt: $updatedAt, ')
|
|
..write('lastSyncedAt: $lastSyncedAt, ')
|
|
..write('dirty: $dirty, ')
|
|
..write('rowid: $rowid')
|
|
..write(')'))
|
|
.toString();
|
|
}
|
|
}
|
|
|
|
class $SyncOutboxRowsTable extends SyncOutboxRows
|
|
with TableInfo<$SyncOutboxRowsTable, SyncOutboxRow> {
|
|
@override
|
|
final GeneratedDatabase attachedDatabase;
|
|
final String? _alias;
|
|
$SyncOutboxRowsTable(this.attachedDatabase, [this._alias]);
|
|
static const VerificationMeta _idMeta = const VerificationMeta('id');
|
|
@override
|
|
late final GeneratedColumn<int> id = GeneratedColumn<int>(
|
|
'id',
|
|
aliasedName,
|
|
false,
|
|
hasAutoIncrement: true,
|
|
type: DriftSqlType.int,
|
|
requiredDuringInsert: false,
|
|
defaultConstraints: GeneratedColumn.constraintIsAlways(
|
|
'PRIMARY KEY AUTOINCREMENT',
|
|
),
|
|
);
|
|
static const VerificationMeta _firebaseUidMeta = const VerificationMeta(
|
|
'firebaseUid',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<String> firebaseUid = GeneratedColumn<String>(
|
|
'firebase_uid',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: true,
|
|
);
|
|
static const VerificationMeta _payloadJsonMeta = const VerificationMeta(
|
|
'payloadJson',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<String> payloadJson = GeneratedColumn<String>(
|
|
'payload_json',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.string,
|
|
requiredDuringInsert: true,
|
|
);
|
|
static const VerificationMeta _createdAtMeta = const VerificationMeta(
|
|
'createdAt',
|
|
);
|
|
@override
|
|
late final GeneratedColumn<DateTime> createdAt = GeneratedColumn<DateTime>(
|
|
'created_at',
|
|
aliasedName,
|
|
false,
|
|
type: DriftSqlType.dateTime,
|
|
requiredDuringInsert: true,
|
|
);
|
|
@override
|
|
List<GeneratedColumn> get $columns => [
|
|
id,
|
|
firebaseUid,
|
|
payloadJson,
|
|
createdAt,
|
|
];
|
|
@override
|
|
String get aliasedName => _alias ?? actualTableName;
|
|
@override
|
|
String get actualTableName => $name;
|
|
static const String $name = 'sync_outbox_rows';
|
|
@override
|
|
VerificationContext validateIntegrity(
|
|
Insertable<SyncOutboxRow> instance, {
|
|
bool isInserting = false,
|
|
}) {
|
|
final context = VerificationContext();
|
|
final data = instance.toColumns(true);
|
|
if (data.containsKey('id')) {
|
|
context.handle(_idMeta, id.isAcceptableOrUnknown(data['id']!, _idMeta));
|
|
}
|
|
if (data.containsKey('firebase_uid')) {
|
|
context.handle(
|
|
_firebaseUidMeta,
|
|
firebaseUid.isAcceptableOrUnknown(
|
|
data['firebase_uid']!,
|
|
_firebaseUidMeta,
|
|
),
|
|
);
|
|
} else if (isInserting) {
|
|
context.missing(_firebaseUidMeta);
|
|
}
|
|
if (data.containsKey('payload_json')) {
|
|
context.handle(
|
|
_payloadJsonMeta,
|
|
payloadJson.isAcceptableOrUnknown(
|
|
data['payload_json']!,
|
|
_payloadJsonMeta,
|
|
),
|
|
);
|
|
} else if (isInserting) {
|
|
context.missing(_payloadJsonMeta);
|
|
}
|
|
if (data.containsKey('created_at')) {
|
|
context.handle(
|
|
_createdAtMeta,
|
|
createdAt.isAcceptableOrUnknown(data['created_at']!, _createdAtMeta),
|
|
);
|
|
} else if (isInserting) {
|
|
context.missing(_createdAtMeta);
|
|
}
|
|
return context;
|
|
}
|
|
|
|
@override
|
|
Set<GeneratedColumn> get $primaryKey => {id};
|
|
@override
|
|
SyncOutboxRow map(Map<String, dynamic> data, {String? tablePrefix}) {
|
|
final effectivePrefix = tablePrefix != null ? '$tablePrefix.' : '';
|
|
return SyncOutboxRow(
|
|
id: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.int,
|
|
data['${effectivePrefix}id'],
|
|
)!,
|
|
firebaseUid: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}firebase_uid'],
|
|
)!,
|
|
payloadJson: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.string,
|
|
data['${effectivePrefix}payload_json'],
|
|
)!,
|
|
createdAt: attachedDatabase.typeMapping.read(
|
|
DriftSqlType.dateTime,
|
|
data['${effectivePrefix}created_at'],
|
|
)!,
|
|
);
|
|
}
|
|
|
|
@override
|
|
$SyncOutboxRowsTable createAlias(String alias) {
|
|
return $SyncOutboxRowsTable(attachedDatabase, alias);
|
|
}
|
|
}
|
|
|
|
class SyncOutboxRow extends DataClass implements Insertable<SyncOutboxRow> {
|
|
final int id;
|
|
final String firebaseUid;
|
|
final String payloadJson;
|
|
final DateTime createdAt;
|
|
const SyncOutboxRow({
|
|
required this.id,
|
|
required this.firebaseUid,
|
|
required this.payloadJson,
|
|
required this.createdAt,
|
|
});
|
|
@override
|
|
Map<String, Expression> toColumns(bool nullToAbsent) {
|
|
final map = <String, Expression>{};
|
|
map['id'] = Variable<int>(id);
|
|
map['firebase_uid'] = Variable<String>(firebaseUid);
|
|
map['payload_json'] = Variable<String>(payloadJson);
|
|
map['created_at'] = Variable<DateTime>(createdAt);
|
|
return map;
|
|
}
|
|
|
|
SyncOutboxRowsCompanion toCompanion(bool nullToAbsent) {
|
|
return SyncOutboxRowsCompanion(
|
|
id: Value(id),
|
|
firebaseUid: Value(firebaseUid),
|
|
payloadJson: Value(payloadJson),
|
|
createdAt: Value(createdAt),
|
|
);
|
|
}
|
|
|
|
factory SyncOutboxRow.fromJson(
|
|
Map<String, dynamic> json, {
|
|
ValueSerializer? serializer,
|
|
}) {
|
|
serializer ??= driftRuntimeOptions.defaultSerializer;
|
|
return SyncOutboxRow(
|
|
id: serializer.fromJson<int>(json['id']),
|
|
firebaseUid: serializer.fromJson<String>(json['firebaseUid']),
|
|
payloadJson: serializer.fromJson<String>(json['payloadJson']),
|
|
createdAt: serializer.fromJson<DateTime>(json['createdAt']),
|
|
);
|
|
}
|
|
@override
|
|
Map<String, dynamic> toJson({ValueSerializer? serializer}) {
|
|
serializer ??= driftRuntimeOptions.defaultSerializer;
|
|
return <String, dynamic>{
|
|
'id': serializer.toJson<int>(id),
|
|
'firebaseUid': serializer.toJson<String>(firebaseUid),
|
|
'payloadJson': serializer.toJson<String>(payloadJson),
|
|
'createdAt': serializer.toJson<DateTime>(createdAt),
|
|
};
|
|
}
|
|
|
|
SyncOutboxRow copyWith({
|
|
int? id,
|
|
String? firebaseUid,
|
|
String? payloadJson,
|
|
DateTime? createdAt,
|
|
}) => SyncOutboxRow(
|
|
id: id ?? this.id,
|
|
firebaseUid: firebaseUid ?? this.firebaseUid,
|
|
payloadJson: payloadJson ?? this.payloadJson,
|
|
createdAt: createdAt ?? this.createdAt,
|
|
);
|
|
SyncOutboxRow copyWithCompanion(SyncOutboxRowsCompanion data) {
|
|
return SyncOutboxRow(
|
|
id: data.id.present ? data.id.value : this.id,
|
|
firebaseUid: data.firebaseUid.present
|
|
? data.firebaseUid.value
|
|
: this.firebaseUid,
|
|
payloadJson: data.payloadJson.present
|
|
? data.payloadJson.value
|
|
: this.payloadJson,
|
|
createdAt: data.createdAt.present ? data.createdAt.value : this.createdAt,
|
|
);
|
|
}
|
|
|
|
@override
|
|
String toString() {
|
|
return (StringBuffer('SyncOutboxRow(')
|
|
..write('id: $id, ')
|
|
..write('firebaseUid: $firebaseUid, ')
|
|
..write('payloadJson: $payloadJson, ')
|
|
..write('createdAt: $createdAt')
|
|
..write(')'))
|
|
.toString();
|
|
}
|
|
|
|
@override
|
|
int get hashCode => Object.hash(id, firebaseUid, payloadJson, createdAt);
|
|
@override
|
|
bool operator ==(Object other) =>
|
|
identical(this, other) ||
|
|
(other is SyncOutboxRow &&
|
|
other.id == this.id &&
|
|
other.firebaseUid == this.firebaseUid &&
|
|
other.payloadJson == this.payloadJson &&
|
|
other.createdAt == this.createdAt);
|
|
}
|
|
|
|
class SyncOutboxRowsCompanion extends UpdateCompanion<SyncOutboxRow> {
|
|
final Value<int> id;
|
|
final Value<String> firebaseUid;
|
|
final Value<String> payloadJson;
|
|
final Value<DateTime> createdAt;
|
|
const SyncOutboxRowsCompanion({
|
|
this.id = const Value.absent(),
|
|
this.firebaseUid = const Value.absent(),
|
|
this.payloadJson = const Value.absent(),
|
|
this.createdAt = const Value.absent(),
|
|
});
|
|
SyncOutboxRowsCompanion.insert({
|
|
this.id = const Value.absent(),
|
|
required String firebaseUid,
|
|
required String payloadJson,
|
|
required DateTime createdAt,
|
|
}) : firebaseUid = Value(firebaseUid),
|
|
payloadJson = Value(payloadJson),
|
|
createdAt = Value(createdAt);
|
|
static Insertable<SyncOutboxRow> custom({
|
|
Expression<int>? id,
|
|
Expression<String>? firebaseUid,
|
|
Expression<String>? payloadJson,
|
|
Expression<DateTime>? createdAt,
|
|
}) {
|
|
return RawValuesInsertable({
|
|
if (id != null) 'id': id,
|
|
if (firebaseUid != null) 'firebase_uid': firebaseUid,
|
|
if (payloadJson != null) 'payload_json': payloadJson,
|
|
if (createdAt != null) 'created_at': createdAt,
|
|
});
|
|
}
|
|
|
|
SyncOutboxRowsCompanion copyWith({
|
|
Value<int>? id,
|
|
Value<String>? firebaseUid,
|
|
Value<String>? payloadJson,
|
|
Value<DateTime>? createdAt,
|
|
}) {
|
|
return SyncOutboxRowsCompanion(
|
|
id: id ?? this.id,
|
|
firebaseUid: firebaseUid ?? this.firebaseUid,
|
|
payloadJson: payloadJson ?? this.payloadJson,
|
|
createdAt: createdAt ?? this.createdAt,
|
|
);
|
|
}
|
|
|
|
@override
|
|
Map<String, Expression> toColumns(bool nullToAbsent) {
|
|
final map = <String, Expression>{};
|
|
if (id.present) {
|
|
map['id'] = Variable<int>(id.value);
|
|
}
|
|
if (firebaseUid.present) {
|
|
map['firebase_uid'] = Variable<String>(firebaseUid.value);
|
|
}
|
|
if (payloadJson.present) {
|
|
map['payload_json'] = Variable<String>(payloadJson.value);
|
|
}
|
|
if (createdAt.present) {
|
|
map['created_at'] = Variable<DateTime>(createdAt.value);
|
|
}
|
|
return map;
|
|
}
|
|
|
|
@override
|
|
String toString() {
|
|
return (StringBuffer('SyncOutboxRowsCompanion(')
|
|
..write('id: $id, ')
|
|
..write('firebaseUid: $firebaseUid, ')
|
|
..write('payloadJson: $payloadJson, ')
|
|
..write('createdAt: $createdAt')
|
|
..write(')'))
|
|
.toString();
|
|
}
|
|
}
|
|
|
|
abstract class _$AppDatabase extends GeneratedDatabase {
|
|
_$AppDatabase(QueryExecutor e) : super(e);
|
|
$AppDatabaseManager get managers => $AppDatabaseManager(this);
|
|
late final $UserProfileRowsTable userProfileRows = $UserProfileRowsTable(
|
|
this,
|
|
);
|
|
late final $SyncOutboxRowsTable syncOutboxRows = $SyncOutboxRowsTable(this);
|
|
@override
|
|
Iterable<TableInfo<Table, Object?>> get allTables =>
|
|
allSchemaEntities.whereType<TableInfo<Table, Object?>>();
|
|
@override
|
|
List<DatabaseSchemaEntity> get allSchemaEntities => [
|
|
userProfileRows,
|
|
syncOutboxRows,
|
|
];
|
|
}
|
|
|
|
typedef $$UserProfileRowsTableCreateCompanionBuilder =
|
|
UserProfileRowsCompanion Function({
|
|
required String firebaseUid,
|
|
Value<String?> email,
|
|
Value<String?> displayName,
|
|
Value<String?> photoUrl,
|
|
Value<String> locale,
|
|
Value<String?> timezone,
|
|
Value<bool> onboardingCompleted,
|
|
Value<int> revision,
|
|
required DateTime updatedAt,
|
|
Value<DateTime?> lastSyncedAt,
|
|
Value<bool> dirty,
|
|
Value<int> rowid,
|
|
});
|
|
typedef $$UserProfileRowsTableUpdateCompanionBuilder =
|
|
UserProfileRowsCompanion Function({
|
|
Value<String> firebaseUid,
|
|
Value<String?> email,
|
|
Value<String?> displayName,
|
|
Value<String?> photoUrl,
|
|
Value<String> locale,
|
|
Value<String?> timezone,
|
|
Value<bool> onboardingCompleted,
|
|
Value<int> revision,
|
|
Value<DateTime> updatedAt,
|
|
Value<DateTime?> lastSyncedAt,
|
|
Value<bool> dirty,
|
|
Value<int> rowid,
|
|
});
|
|
|
|
class $$UserProfileRowsTableFilterComposer
|
|
extends Composer<_$AppDatabase, $UserProfileRowsTable> {
|
|
$$UserProfileRowsTableFilterComposer({
|
|
required super.$db,
|
|
required super.$table,
|
|
super.joinBuilder,
|
|
super.$addJoinBuilderToRootComposer,
|
|
super.$removeJoinBuilderFromRootComposer,
|
|
});
|
|
ColumnFilters<String> get firebaseUid => $composableBuilder(
|
|
column: $table.firebaseUid,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get email => $composableBuilder(
|
|
column: $table.email,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get displayName => $composableBuilder(
|
|
column: $table.displayName,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get photoUrl => $composableBuilder(
|
|
column: $table.photoUrl,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get locale => $composableBuilder(
|
|
column: $table.locale,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get timezone => $composableBuilder(
|
|
column: $table.timezone,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<bool> get onboardingCompleted => $composableBuilder(
|
|
column: $table.onboardingCompleted,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<int> get revision => $composableBuilder(
|
|
column: $table.revision,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<DateTime> get updatedAt => $composableBuilder(
|
|
column: $table.updatedAt,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<DateTime> get lastSyncedAt => $composableBuilder(
|
|
column: $table.lastSyncedAt,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<bool> get dirty => $composableBuilder(
|
|
column: $table.dirty,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
}
|
|
|
|
class $$UserProfileRowsTableOrderingComposer
|
|
extends Composer<_$AppDatabase, $UserProfileRowsTable> {
|
|
$$UserProfileRowsTableOrderingComposer({
|
|
required super.$db,
|
|
required super.$table,
|
|
super.joinBuilder,
|
|
super.$addJoinBuilderToRootComposer,
|
|
super.$removeJoinBuilderFromRootComposer,
|
|
});
|
|
ColumnOrderings<String> get firebaseUid => $composableBuilder(
|
|
column: $table.firebaseUid,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get email => $composableBuilder(
|
|
column: $table.email,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get displayName => $composableBuilder(
|
|
column: $table.displayName,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get photoUrl => $composableBuilder(
|
|
column: $table.photoUrl,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get locale => $composableBuilder(
|
|
column: $table.locale,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get timezone => $composableBuilder(
|
|
column: $table.timezone,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<bool> get onboardingCompleted => $composableBuilder(
|
|
column: $table.onboardingCompleted,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<int> get revision => $composableBuilder(
|
|
column: $table.revision,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<DateTime> get updatedAt => $composableBuilder(
|
|
column: $table.updatedAt,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<DateTime> get lastSyncedAt => $composableBuilder(
|
|
column: $table.lastSyncedAt,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<bool> get dirty => $composableBuilder(
|
|
column: $table.dirty,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
}
|
|
|
|
class $$UserProfileRowsTableAnnotationComposer
|
|
extends Composer<_$AppDatabase, $UserProfileRowsTable> {
|
|
$$UserProfileRowsTableAnnotationComposer({
|
|
required super.$db,
|
|
required super.$table,
|
|
super.joinBuilder,
|
|
super.$addJoinBuilderToRootComposer,
|
|
super.$removeJoinBuilderFromRootComposer,
|
|
});
|
|
GeneratedColumn<String> get firebaseUid => $composableBuilder(
|
|
column: $table.firebaseUid,
|
|
builder: (column) => column,
|
|
);
|
|
|
|
GeneratedColumn<String> get email =>
|
|
$composableBuilder(column: $table.email, builder: (column) => column);
|
|
|
|
GeneratedColumn<String> get displayName => $composableBuilder(
|
|
column: $table.displayName,
|
|
builder: (column) => column,
|
|
);
|
|
|
|
GeneratedColumn<String> get photoUrl =>
|
|
$composableBuilder(column: $table.photoUrl, builder: (column) => column);
|
|
|
|
GeneratedColumn<String> get locale =>
|
|
$composableBuilder(column: $table.locale, builder: (column) => column);
|
|
|
|
GeneratedColumn<String> get timezone =>
|
|
$composableBuilder(column: $table.timezone, builder: (column) => column);
|
|
|
|
GeneratedColumn<bool> get onboardingCompleted => $composableBuilder(
|
|
column: $table.onboardingCompleted,
|
|
builder: (column) => column,
|
|
);
|
|
|
|
GeneratedColumn<int> get revision =>
|
|
$composableBuilder(column: $table.revision, builder: (column) => column);
|
|
|
|
GeneratedColumn<DateTime> get updatedAt =>
|
|
$composableBuilder(column: $table.updatedAt, builder: (column) => column);
|
|
|
|
GeneratedColumn<DateTime> get lastSyncedAt => $composableBuilder(
|
|
column: $table.lastSyncedAt,
|
|
builder: (column) => column,
|
|
);
|
|
|
|
GeneratedColumn<bool> get dirty =>
|
|
$composableBuilder(column: $table.dirty, builder: (column) => column);
|
|
}
|
|
|
|
class $$UserProfileRowsTableTableManager
|
|
extends
|
|
RootTableManager<
|
|
_$AppDatabase,
|
|
$UserProfileRowsTable,
|
|
UserProfileRow,
|
|
$$UserProfileRowsTableFilterComposer,
|
|
$$UserProfileRowsTableOrderingComposer,
|
|
$$UserProfileRowsTableAnnotationComposer,
|
|
$$UserProfileRowsTableCreateCompanionBuilder,
|
|
$$UserProfileRowsTableUpdateCompanionBuilder,
|
|
(
|
|
UserProfileRow,
|
|
BaseReferences<
|
|
_$AppDatabase,
|
|
$UserProfileRowsTable,
|
|
UserProfileRow
|
|
>,
|
|
),
|
|
UserProfileRow,
|
|
PrefetchHooks Function()
|
|
> {
|
|
$$UserProfileRowsTableTableManager(
|
|
_$AppDatabase db,
|
|
$UserProfileRowsTable table,
|
|
) : super(
|
|
TableManagerState(
|
|
db: db,
|
|
table: table,
|
|
createFilteringComposer: () =>
|
|
$$UserProfileRowsTableFilterComposer($db: db, $table: table),
|
|
createOrderingComposer: () =>
|
|
$$UserProfileRowsTableOrderingComposer($db: db, $table: table),
|
|
createComputedFieldComposer: () =>
|
|
$$UserProfileRowsTableAnnotationComposer($db: db, $table: table),
|
|
updateCompanionCallback:
|
|
({
|
|
Value<String> firebaseUid = const Value.absent(),
|
|
Value<String?> email = const Value.absent(),
|
|
Value<String?> displayName = const Value.absent(),
|
|
Value<String?> photoUrl = const Value.absent(),
|
|
Value<String> locale = const Value.absent(),
|
|
Value<String?> timezone = const Value.absent(),
|
|
Value<bool> onboardingCompleted = const Value.absent(),
|
|
Value<int> revision = const Value.absent(),
|
|
Value<DateTime> updatedAt = const Value.absent(),
|
|
Value<DateTime?> lastSyncedAt = const Value.absent(),
|
|
Value<bool> dirty = const Value.absent(),
|
|
Value<int> rowid = const Value.absent(),
|
|
}) => UserProfileRowsCompanion(
|
|
firebaseUid: firebaseUid,
|
|
email: email,
|
|
displayName: displayName,
|
|
photoUrl: photoUrl,
|
|
locale: locale,
|
|
timezone: timezone,
|
|
onboardingCompleted: onboardingCompleted,
|
|
revision: revision,
|
|
updatedAt: updatedAt,
|
|
lastSyncedAt: lastSyncedAt,
|
|
dirty: dirty,
|
|
rowid: rowid,
|
|
),
|
|
createCompanionCallback:
|
|
({
|
|
required String firebaseUid,
|
|
Value<String?> email = const Value.absent(),
|
|
Value<String?> displayName = const Value.absent(),
|
|
Value<String?> photoUrl = const Value.absent(),
|
|
Value<String> locale = const Value.absent(),
|
|
Value<String?> timezone = const Value.absent(),
|
|
Value<bool> onboardingCompleted = const Value.absent(),
|
|
Value<int> revision = const Value.absent(),
|
|
required DateTime updatedAt,
|
|
Value<DateTime?> lastSyncedAt = const Value.absent(),
|
|
Value<bool> dirty = const Value.absent(),
|
|
Value<int> rowid = const Value.absent(),
|
|
}) => UserProfileRowsCompanion.insert(
|
|
firebaseUid: firebaseUid,
|
|
email: email,
|
|
displayName: displayName,
|
|
photoUrl: photoUrl,
|
|
locale: locale,
|
|
timezone: timezone,
|
|
onboardingCompleted: onboardingCompleted,
|
|
revision: revision,
|
|
updatedAt: updatedAt,
|
|
lastSyncedAt: lastSyncedAt,
|
|
dirty: dirty,
|
|
rowid: rowid,
|
|
),
|
|
withReferenceMapper: (p0) => p0
|
|
.map((e) => (e.readTable(table), BaseReferences(db, table, e)))
|
|
.toList(),
|
|
prefetchHooksCallback: null,
|
|
),
|
|
);
|
|
}
|
|
|
|
typedef $$UserProfileRowsTableProcessedTableManager =
|
|
ProcessedTableManager<
|
|
_$AppDatabase,
|
|
$UserProfileRowsTable,
|
|
UserProfileRow,
|
|
$$UserProfileRowsTableFilterComposer,
|
|
$$UserProfileRowsTableOrderingComposer,
|
|
$$UserProfileRowsTableAnnotationComposer,
|
|
$$UserProfileRowsTableCreateCompanionBuilder,
|
|
$$UserProfileRowsTableUpdateCompanionBuilder,
|
|
(
|
|
UserProfileRow,
|
|
BaseReferences<_$AppDatabase, $UserProfileRowsTable, UserProfileRow>,
|
|
),
|
|
UserProfileRow,
|
|
PrefetchHooks Function()
|
|
>;
|
|
typedef $$SyncOutboxRowsTableCreateCompanionBuilder =
|
|
SyncOutboxRowsCompanion Function({
|
|
Value<int> id,
|
|
required String firebaseUid,
|
|
required String payloadJson,
|
|
required DateTime createdAt,
|
|
});
|
|
typedef $$SyncOutboxRowsTableUpdateCompanionBuilder =
|
|
SyncOutboxRowsCompanion Function({
|
|
Value<int> id,
|
|
Value<String> firebaseUid,
|
|
Value<String> payloadJson,
|
|
Value<DateTime> createdAt,
|
|
});
|
|
|
|
class $$SyncOutboxRowsTableFilterComposer
|
|
extends Composer<_$AppDatabase, $SyncOutboxRowsTable> {
|
|
$$SyncOutboxRowsTableFilterComposer({
|
|
required super.$db,
|
|
required super.$table,
|
|
super.joinBuilder,
|
|
super.$addJoinBuilderToRootComposer,
|
|
super.$removeJoinBuilderFromRootComposer,
|
|
});
|
|
ColumnFilters<int> get id => $composableBuilder(
|
|
column: $table.id,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get firebaseUid => $composableBuilder(
|
|
column: $table.firebaseUid,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<String> get payloadJson => $composableBuilder(
|
|
column: $table.payloadJson,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
|
|
ColumnFilters<DateTime> get createdAt => $composableBuilder(
|
|
column: $table.createdAt,
|
|
builder: (column) => ColumnFilters(column),
|
|
);
|
|
}
|
|
|
|
class $$SyncOutboxRowsTableOrderingComposer
|
|
extends Composer<_$AppDatabase, $SyncOutboxRowsTable> {
|
|
$$SyncOutboxRowsTableOrderingComposer({
|
|
required super.$db,
|
|
required super.$table,
|
|
super.joinBuilder,
|
|
super.$addJoinBuilderToRootComposer,
|
|
super.$removeJoinBuilderFromRootComposer,
|
|
});
|
|
ColumnOrderings<int> get id => $composableBuilder(
|
|
column: $table.id,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get firebaseUid => $composableBuilder(
|
|
column: $table.firebaseUid,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<String> get payloadJson => $composableBuilder(
|
|
column: $table.payloadJson,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
|
|
ColumnOrderings<DateTime> get createdAt => $composableBuilder(
|
|
column: $table.createdAt,
|
|
builder: (column) => ColumnOrderings(column),
|
|
);
|
|
}
|
|
|
|
class $$SyncOutboxRowsTableAnnotationComposer
|
|
extends Composer<_$AppDatabase, $SyncOutboxRowsTable> {
|
|
$$SyncOutboxRowsTableAnnotationComposer({
|
|
required super.$db,
|
|
required super.$table,
|
|
super.joinBuilder,
|
|
super.$addJoinBuilderToRootComposer,
|
|
super.$removeJoinBuilderFromRootComposer,
|
|
});
|
|
GeneratedColumn<int> get id =>
|
|
$composableBuilder(column: $table.id, builder: (column) => column);
|
|
|
|
GeneratedColumn<String> get firebaseUid => $composableBuilder(
|
|
column: $table.firebaseUid,
|
|
builder: (column) => column,
|
|
);
|
|
|
|
GeneratedColumn<String> get payloadJson => $composableBuilder(
|
|
column: $table.payloadJson,
|
|
builder: (column) => column,
|
|
);
|
|
|
|
GeneratedColumn<DateTime> get createdAt =>
|
|
$composableBuilder(column: $table.createdAt, builder: (column) => column);
|
|
}
|
|
|
|
class $$SyncOutboxRowsTableTableManager
|
|
extends
|
|
RootTableManager<
|
|
_$AppDatabase,
|
|
$SyncOutboxRowsTable,
|
|
SyncOutboxRow,
|
|
$$SyncOutboxRowsTableFilterComposer,
|
|
$$SyncOutboxRowsTableOrderingComposer,
|
|
$$SyncOutboxRowsTableAnnotationComposer,
|
|
$$SyncOutboxRowsTableCreateCompanionBuilder,
|
|
$$SyncOutboxRowsTableUpdateCompanionBuilder,
|
|
(
|
|
SyncOutboxRow,
|
|
BaseReferences<_$AppDatabase, $SyncOutboxRowsTable, SyncOutboxRow>,
|
|
),
|
|
SyncOutboxRow,
|
|
PrefetchHooks Function()
|
|
> {
|
|
$$SyncOutboxRowsTableTableManager(
|
|
_$AppDatabase db,
|
|
$SyncOutboxRowsTable table,
|
|
) : super(
|
|
TableManagerState(
|
|
db: db,
|
|
table: table,
|
|
createFilteringComposer: () =>
|
|
$$SyncOutboxRowsTableFilterComposer($db: db, $table: table),
|
|
createOrderingComposer: () =>
|
|
$$SyncOutboxRowsTableOrderingComposer($db: db, $table: table),
|
|
createComputedFieldComposer: () =>
|
|
$$SyncOutboxRowsTableAnnotationComposer($db: db, $table: table),
|
|
updateCompanionCallback:
|
|
({
|
|
Value<int> id = const Value.absent(),
|
|
Value<String> firebaseUid = const Value.absent(),
|
|
Value<String> payloadJson = const Value.absent(),
|
|
Value<DateTime> createdAt = const Value.absent(),
|
|
}) => SyncOutboxRowsCompanion(
|
|
id: id,
|
|
firebaseUid: firebaseUid,
|
|
payloadJson: payloadJson,
|
|
createdAt: createdAt,
|
|
),
|
|
createCompanionCallback:
|
|
({
|
|
Value<int> id = const Value.absent(),
|
|
required String firebaseUid,
|
|
required String payloadJson,
|
|
required DateTime createdAt,
|
|
}) => SyncOutboxRowsCompanion.insert(
|
|
id: id,
|
|
firebaseUid: firebaseUid,
|
|
payloadJson: payloadJson,
|
|
createdAt: createdAt,
|
|
),
|
|
withReferenceMapper: (p0) => p0
|
|
.map((e) => (e.readTable(table), BaseReferences(db, table, e)))
|
|
.toList(),
|
|
prefetchHooksCallback: null,
|
|
),
|
|
);
|
|
}
|
|
|
|
typedef $$SyncOutboxRowsTableProcessedTableManager =
|
|
ProcessedTableManager<
|
|
_$AppDatabase,
|
|
$SyncOutboxRowsTable,
|
|
SyncOutboxRow,
|
|
$$SyncOutboxRowsTableFilterComposer,
|
|
$$SyncOutboxRowsTableOrderingComposer,
|
|
$$SyncOutboxRowsTableAnnotationComposer,
|
|
$$SyncOutboxRowsTableCreateCompanionBuilder,
|
|
$$SyncOutboxRowsTableUpdateCompanionBuilder,
|
|
(
|
|
SyncOutboxRow,
|
|
BaseReferences<_$AppDatabase, $SyncOutboxRowsTable, SyncOutboxRow>,
|
|
),
|
|
SyncOutboxRow,
|
|
PrefetchHooks Function()
|
|
>;
|
|
|
|
class $AppDatabaseManager {
|
|
final _$AppDatabase _db;
|
|
$AppDatabaseManager(this._db);
|
|
$$UserProfileRowsTableTableManager get userProfileRows =>
|
|
$$UserProfileRowsTableTableManager(_db, _db.userProfileRows);
|
|
$$SyncOutboxRowsTableTableManager get syncOutboxRows =>
|
|
$$SyncOutboxRowsTableTableManager(_db, _db.syncOutboxRows);
|
|
}
|