// GENERATED CODE - DO NOT MODIFY BY HAND part of 'app_database.dart'; // ignore_for_file: type=lint class $UsersTable extends Users with TableInfo<$UsersTable, UserRow> { @override final GeneratedDatabase attachedDatabase; final String? _alias; $UsersTable(this.attachedDatabase, [this._alias]); @override late final GeneratedColumnWithTypeConverter syncStatus = GeneratedColumn( 'sync_status', aliasedName, false, type: DriftSqlType.int, requiredDuringInsert: false, defaultValue: const Constant(0), ).withConverter($UsersTable.$convertersyncStatus); static const VerificationMeta _localUpdatedAtMeta = const VerificationMeta( 'localUpdatedAt', ); @override late final GeneratedColumn localUpdatedAt = GeneratedColumn( 'local_updated_at', aliasedName, false, type: DriftSqlType.dateTime, requiredDuringInsert: false, defaultValue: currentDateAndTime, ); static const VerificationMeta _serverUpdatedAtMeta = const VerificationMeta( 'serverUpdatedAt', ); @override late final GeneratedColumn serverUpdatedAt = GeneratedColumn( 'server_updated_at', aliasedName, true, type: DriftSqlType.dateTime, requiredDuringInsert: false, ); static const VerificationMeta _conflictPayloadMeta = const VerificationMeta( 'conflictPayload', ); @override late final GeneratedColumn conflictPayload = GeneratedColumn( 'conflict_payload', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _userIdMeta = const VerificationMeta('userId'); @override late final GeneratedColumn userId = GeneratedColumn( 'user_id', aliasedName, false, type: DriftSqlType.string, requiredDuringInsert: true, ); static const VerificationMeta _usernameMeta = const VerificationMeta( 'username', ); @override late final GeneratedColumn username = GeneratedColumn( 'username', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _realNameMeta = const VerificationMeta( 'realName', ); @override late final GeneratedColumn realName = GeneratedColumn( 'real_name', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _phoneMeta = const VerificationMeta('phone'); @override late final GeneratedColumn phone = GeneratedColumn( 'phone', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _avatarMeta = const VerificationMeta('avatar'); @override late final GeneratedColumn avatar = GeneratedColumn( 'avatar', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _genderMeta = const VerificationMeta('gender'); @override late final GeneratedColumn gender = GeneratedColumn( 'gender', aliasedName, true, type: DriftSqlType.int, requiredDuringInsert: false, ); static const VerificationMeta _ageMeta = const VerificationMeta('age'); @override late final GeneratedColumn age = GeneratedColumn( 'age', aliasedName, true, type: DriftSqlType.int, requiredDuringInsert: false, ); static const VerificationMeta _refreshTokenMeta = const VerificationMeta( 'refreshToken', ); @override late final GeneratedColumn refreshToken = GeneratedColumn( 'refresh_token', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _emailMeta = const VerificationMeta('email'); @override late final GeneratedColumn email = GeneratedColumn( 'email', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _birthdayMeta = const VerificationMeta( 'birthday', ); @override late final GeneratedColumn birthday = GeneratedColumn( 'birthday', aliasedName, true, type: DriftSqlType.dateTime, requiredDuringInsert: false, ); static const VerificationMeta _employeeNoMeta = const VerificationMeta( 'employeeNo', ); @override late final GeneratedColumn employeeNo = GeneratedColumn( 'employee_no', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _companyMeta = const VerificationMeta( 'company', ); @override late final GeneratedColumn company = GeneratedColumn( 'company', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _departmentMeta = const VerificationMeta( 'department', ); @override late final GeneratedColumn department = GeneratedColumn( 'department', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); @override List get $columns => [ syncStatus, localUpdatedAt, serverUpdatedAt, conflictPayload, userId, username, realName, phone, avatar, gender, age, refreshToken, email, birthday, employeeNo, company, department, ]; @override String get aliasedName => _alias ?? actualTableName; @override String get actualTableName => $name; static const String $name = 'users'; @override VerificationContext validateIntegrity( Insertable instance, { bool isInserting = false, }) { final context = VerificationContext(); final data = instance.toColumns(true); if (data.containsKey('local_updated_at')) { context.handle( _localUpdatedAtMeta, localUpdatedAt.isAcceptableOrUnknown( data['local_updated_at']!, _localUpdatedAtMeta, ), ); } if (data.containsKey('server_updated_at')) { context.handle( _serverUpdatedAtMeta, serverUpdatedAt.isAcceptableOrUnknown( data['server_updated_at']!, _serverUpdatedAtMeta, ), ); } if (data.containsKey('conflict_payload')) { context.handle( _conflictPayloadMeta, conflictPayload.isAcceptableOrUnknown( data['conflict_payload']!, _conflictPayloadMeta, ), ); } if (data.containsKey('user_id')) { context.handle( _userIdMeta, userId.isAcceptableOrUnknown(data['user_id']!, _userIdMeta), ); } else if (isInserting) { context.missing(_userIdMeta); } if (data.containsKey('username')) { context.handle( _usernameMeta, username.isAcceptableOrUnknown(data['username']!, _usernameMeta), ); } if (data.containsKey('real_name')) { context.handle( _realNameMeta, realName.isAcceptableOrUnknown(data['real_name']!, _realNameMeta), ); } if (data.containsKey('phone')) { context.handle( _phoneMeta, phone.isAcceptableOrUnknown(data['phone']!, _phoneMeta), ); } if (data.containsKey('avatar')) { context.handle( _avatarMeta, avatar.isAcceptableOrUnknown(data['avatar']!, _avatarMeta), ); } if (data.containsKey('gender')) { context.handle( _genderMeta, gender.isAcceptableOrUnknown(data['gender']!, _genderMeta), ); } if (data.containsKey('age')) { context.handle( _ageMeta, age.isAcceptableOrUnknown(data['age']!, _ageMeta), ); } if (data.containsKey('refresh_token')) { context.handle( _refreshTokenMeta, refreshToken.isAcceptableOrUnknown( data['refresh_token']!, _refreshTokenMeta, ), ); } if (data.containsKey('email')) { context.handle( _emailMeta, email.isAcceptableOrUnknown(data['email']!, _emailMeta), ); } if (data.containsKey('birthday')) { context.handle( _birthdayMeta, birthday.isAcceptableOrUnknown(data['birthday']!, _birthdayMeta), ); } if (data.containsKey('employee_no')) { context.handle( _employeeNoMeta, employeeNo.isAcceptableOrUnknown(data['employee_no']!, _employeeNoMeta), ); } if (data.containsKey('company')) { context.handle( _companyMeta, company.isAcceptableOrUnknown(data['company']!, _companyMeta), ); } if (data.containsKey('department')) { context.handle( _departmentMeta, department.isAcceptableOrUnknown(data['department']!, _departmentMeta), ); } return context; } @override Set get $primaryKey => {userId}; @override UserRow map(Map data, {String? tablePrefix}) { final effectivePrefix = tablePrefix != null ? '$tablePrefix.' : ''; return UserRow( syncStatus: $UsersTable.$convertersyncStatus.fromSql( attachedDatabase.typeMapping.read( DriftSqlType.int, data['${effectivePrefix}sync_status'], )!, ), localUpdatedAt: attachedDatabase.typeMapping.read( DriftSqlType.dateTime, data['${effectivePrefix}local_updated_at'], )!, serverUpdatedAt: attachedDatabase.typeMapping.read( DriftSqlType.dateTime, data['${effectivePrefix}server_updated_at'], ), conflictPayload: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}conflict_payload'], ), userId: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}user_id'], )!, username: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}username'], ), realName: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}real_name'], ), phone: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}phone'], ), avatar: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}avatar'], ), gender: attachedDatabase.typeMapping.read( DriftSqlType.int, data['${effectivePrefix}gender'], ), age: attachedDatabase.typeMapping.read( DriftSqlType.int, data['${effectivePrefix}age'], ), refreshToken: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}refresh_token'], ), email: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}email'], ), birthday: attachedDatabase.typeMapping.read( DriftSqlType.dateTime, data['${effectivePrefix}birthday'], ), employeeNo: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}employee_no'], ), company: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}company'], ), department: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}department'], ), ); } @override $UsersTable createAlias(String alias) { return $UsersTable(attachedDatabase, alias); } static JsonTypeConverter2 $convertersyncStatus = const EnumIndexConverter(SyncStatus.values); } class UserRow extends DataClass implements Insertable { final SyncStatus syncStatus; final DateTime localUpdatedAt; final DateTime? serverUpdatedAt; final String? conflictPayload; final String userId; final String? username; final String? realName; final String? phone; final String? avatar; final int? gender; final int? age; final String? refreshToken; final String? email; final DateTime? birthday; final String? employeeNo; final String? company; final String? department; const UserRow({ required this.syncStatus, required this.localUpdatedAt, this.serverUpdatedAt, this.conflictPayload, required this.userId, this.username, this.realName, this.phone, this.avatar, this.gender, this.age, this.refreshToken, this.email, this.birthday, this.employeeNo, this.company, this.department, }); @override Map toColumns(bool nullToAbsent) { final map = {}; { map['sync_status'] = Variable( $UsersTable.$convertersyncStatus.toSql(syncStatus), ); } map['local_updated_at'] = Variable(localUpdatedAt); if (!nullToAbsent || serverUpdatedAt != null) { map['server_updated_at'] = Variable(serverUpdatedAt); } if (!nullToAbsent || conflictPayload != null) { map['conflict_payload'] = Variable(conflictPayload); } map['user_id'] = Variable(userId); if (!nullToAbsent || username != null) { map['username'] = Variable(username); } if (!nullToAbsent || realName != null) { map['real_name'] = Variable(realName); } if (!nullToAbsent || phone != null) { map['phone'] = Variable(phone); } if (!nullToAbsent || avatar != null) { map['avatar'] = Variable(avatar); } if (!nullToAbsent || gender != null) { map['gender'] = Variable(gender); } if (!nullToAbsent || age != null) { map['age'] = Variable(age); } if (!nullToAbsent || refreshToken != null) { map['refresh_token'] = Variable(refreshToken); } if (!nullToAbsent || email != null) { map['email'] = Variable(email); } if (!nullToAbsent || birthday != null) { map['birthday'] = Variable(birthday); } if (!nullToAbsent || employeeNo != null) { map['employee_no'] = Variable(employeeNo); } if (!nullToAbsent || company != null) { map['company'] = Variable(company); } if (!nullToAbsent || department != null) { map['department'] = Variable(department); } return map; } UsersCompanion toCompanion(bool nullToAbsent) { return UsersCompanion( syncStatus: Value(syncStatus), localUpdatedAt: Value(localUpdatedAt), serverUpdatedAt: serverUpdatedAt == null && nullToAbsent ? const Value.absent() : Value(serverUpdatedAt), conflictPayload: conflictPayload == null && nullToAbsent ? const Value.absent() : Value(conflictPayload), userId: Value(userId), username: username == null && nullToAbsent ? const Value.absent() : Value(username), realName: realName == null && nullToAbsent ? const Value.absent() : Value(realName), phone: phone == null && nullToAbsent ? const Value.absent() : Value(phone), avatar: avatar == null && nullToAbsent ? const Value.absent() : Value(avatar), gender: gender == null && nullToAbsent ? const Value.absent() : Value(gender), age: age == null && nullToAbsent ? const Value.absent() : Value(age), refreshToken: refreshToken == null && nullToAbsent ? const Value.absent() : Value(refreshToken), email: email == null && nullToAbsent ? const Value.absent() : Value(email), birthday: birthday == null && nullToAbsent ? const Value.absent() : Value(birthday), employeeNo: employeeNo == null && nullToAbsent ? const Value.absent() : Value(employeeNo), company: company == null && nullToAbsent ? const Value.absent() : Value(company), department: department == null && nullToAbsent ? const Value.absent() : Value(department), ); } factory UserRow.fromJson( Map json, { ValueSerializer? serializer, }) { serializer ??= driftRuntimeOptions.defaultSerializer; return UserRow( syncStatus: $UsersTable.$convertersyncStatus.fromJson( serializer.fromJson(json['syncStatus']), ), localUpdatedAt: serializer.fromJson(json['localUpdatedAt']), serverUpdatedAt: serializer.fromJson(json['serverUpdatedAt']), conflictPayload: serializer.fromJson(json['conflictPayload']), userId: serializer.fromJson(json['userId']), username: serializer.fromJson(json['username']), realName: serializer.fromJson(json['realName']), phone: serializer.fromJson(json['phone']), avatar: serializer.fromJson(json['avatar']), gender: serializer.fromJson(json['gender']), age: serializer.fromJson(json['age']), refreshToken: serializer.fromJson(json['refreshToken']), email: serializer.fromJson(json['email']), birthday: serializer.fromJson(json['birthday']), employeeNo: serializer.fromJson(json['employeeNo']), company: serializer.fromJson(json['company']), department: serializer.fromJson(json['department']), ); } @override Map toJson({ValueSerializer? serializer}) { serializer ??= driftRuntimeOptions.defaultSerializer; return { 'syncStatus': serializer.toJson( $UsersTable.$convertersyncStatus.toJson(syncStatus), ), 'localUpdatedAt': serializer.toJson(localUpdatedAt), 'serverUpdatedAt': serializer.toJson(serverUpdatedAt), 'conflictPayload': serializer.toJson(conflictPayload), 'userId': serializer.toJson(userId), 'username': serializer.toJson(username), 'realName': serializer.toJson(realName), 'phone': serializer.toJson(phone), 'avatar': serializer.toJson(avatar), 'gender': serializer.toJson(gender), 'age': serializer.toJson(age), 'refreshToken': serializer.toJson(refreshToken), 'email': serializer.toJson(email), 'birthday': serializer.toJson(birthday), 'employeeNo': serializer.toJson(employeeNo), 'company': serializer.toJson(company), 'department': serializer.toJson(department), }; } UserRow copyWith({ SyncStatus? syncStatus, DateTime? localUpdatedAt, Value serverUpdatedAt = const Value.absent(), Value conflictPayload = const Value.absent(), String? userId, Value username = const Value.absent(), Value realName = const Value.absent(), Value phone = const Value.absent(), Value avatar = const Value.absent(), Value gender = const Value.absent(), Value age = const Value.absent(), Value refreshToken = const Value.absent(), Value email = const Value.absent(), Value birthday = const Value.absent(), Value employeeNo = const Value.absent(), Value company = const Value.absent(), Value department = const Value.absent(), }) => UserRow( syncStatus: syncStatus ?? this.syncStatus, localUpdatedAt: localUpdatedAt ?? this.localUpdatedAt, serverUpdatedAt: serverUpdatedAt.present ? serverUpdatedAt.value : this.serverUpdatedAt, conflictPayload: conflictPayload.present ? conflictPayload.value : this.conflictPayload, userId: userId ?? this.userId, username: username.present ? username.value : this.username, realName: realName.present ? realName.value : this.realName, phone: phone.present ? phone.value : this.phone, avatar: avatar.present ? avatar.value : this.avatar, gender: gender.present ? gender.value : this.gender, age: age.present ? age.value : this.age, refreshToken: refreshToken.present ? refreshToken.value : this.refreshToken, email: email.present ? email.value : this.email, birthday: birthday.present ? birthday.value : this.birthday, employeeNo: employeeNo.present ? employeeNo.value : this.employeeNo, company: company.present ? company.value : this.company, department: department.present ? department.value : this.department, ); UserRow copyWithCompanion(UsersCompanion data) { return UserRow( syncStatus: data.syncStatus.present ? data.syncStatus.value : this.syncStatus, localUpdatedAt: data.localUpdatedAt.present ? data.localUpdatedAt.value : this.localUpdatedAt, serverUpdatedAt: data.serverUpdatedAt.present ? data.serverUpdatedAt.value : this.serverUpdatedAt, conflictPayload: data.conflictPayload.present ? data.conflictPayload.value : this.conflictPayload, userId: data.userId.present ? data.userId.value : this.userId, username: data.username.present ? data.username.value : this.username, realName: data.realName.present ? data.realName.value : this.realName, phone: data.phone.present ? data.phone.value : this.phone, avatar: data.avatar.present ? data.avatar.value : this.avatar, gender: data.gender.present ? data.gender.value : this.gender, age: data.age.present ? data.age.value : this.age, refreshToken: data.refreshToken.present ? data.refreshToken.value : this.refreshToken, email: data.email.present ? data.email.value : this.email, birthday: data.birthday.present ? data.birthday.value : this.birthday, employeeNo: data.employeeNo.present ? data.employeeNo.value : this.employeeNo, company: data.company.present ? data.company.value : this.company, department: data.department.present ? data.department.value : this.department, ); } @override String toString() { return (StringBuffer('UserRow(') ..write('syncStatus: $syncStatus, ') ..write('localUpdatedAt: $localUpdatedAt, ') ..write('serverUpdatedAt: $serverUpdatedAt, ') ..write('conflictPayload: $conflictPayload, ') ..write('userId: $userId, ') ..write('username: $username, ') ..write('realName: $realName, ') ..write('phone: $phone, ') ..write('avatar: $avatar, ') ..write('gender: $gender, ') ..write('age: $age, ') ..write('refreshToken: $refreshToken, ') ..write('email: $email, ') ..write('birthday: $birthday, ') ..write('employeeNo: $employeeNo, ') ..write('company: $company, ') ..write('department: $department') ..write(')')) .toString(); } @override int get hashCode => Object.hash( syncStatus, localUpdatedAt, serverUpdatedAt, conflictPayload, userId, username, realName, phone, avatar, gender, age, refreshToken, email, birthday, employeeNo, company, department, ); @override bool operator ==(Object other) => identical(this, other) || (other is UserRow && other.syncStatus == this.syncStatus && other.localUpdatedAt == this.localUpdatedAt && other.serverUpdatedAt == this.serverUpdatedAt && other.conflictPayload == this.conflictPayload && other.userId == this.userId && other.username == this.username && other.realName == this.realName && other.phone == this.phone && other.avatar == this.avatar && other.gender == this.gender && other.age == this.age && other.refreshToken == this.refreshToken && other.email == this.email && other.birthday == this.birthday && other.employeeNo == this.employeeNo && other.company == this.company && other.department == this.department); } class UsersCompanion extends UpdateCompanion { final Value syncStatus; final Value localUpdatedAt; final Value serverUpdatedAt; final Value conflictPayload; final Value userId; final Value username; final Value realName; final Value phone; final Value avatar; final Value gender; final Value age; final Value refreshToken; final Value email; final Value birthday; final Value employeeNo; final Value company; final Value department; final Value rowid; const UsersCompanion({ this.syncStatus = const Value.absent(), this.localUpdatedAt = const Value.absent(), this.serverUpdatedAt = const Value.absent(), this.conflictPayload = const Value.absent(), this.userId = const Value.absent(), this.username = const Value.absent(), this.realName = const Value.absent(), this.phone = const Value.absent(), this.avatar = const Value.absent(), this.gender = const Value.absent(), this.age = const Value.absent(), this.refreshToken = const Value.absent(), this.email = const Value.absent(), this.birthday = const Value.absent(), this.employeeNo = const Value.absent(), this.company = const Value.absent(), this.department = const Value.absent(), this.rowid = const Value.absent(), }); UsersCompanion.insert({ this.syncStatus = const Value.absent(), this.localUpdatedAt = const Value.absent(), this.serverUpdatedAt = const Value.absent(), this.conflictPayload = const Value.absent(), required String userId, this.username = const Value.absent(), this.realName = const Value.absent(), this.phone = const Value.absent(), this.avatar = const Value.absent(), this.gender = const Value.absent(), this.age = const Value.absent(), this.refreshToken = const Value.absent(), this.email = const Value.absent(), this.birthday = const Value.absent(), this.employeeNo = const Value.absent(), this.company = const Value.absent(), this.department = const Value.absent(), this.rowid = const Value.absent(), }) : userId = Value(userId); static Insertable custom({ Expression? syncStatus, Expression? localUpdatedAt, Expression? serverUpdatedAt, Expression? conflictPayload, Expression? userId, Expression? username, Expression? realName, Expression? phone, Expression? avatar, Expression? gender, Expression? age, Expression? refreshToken, Expression? email, Expression? birthday, Expression? employeeNo, Expression? company, Expression? department, Expression? rowid, }) { return RawValuesInsertable({ if (syncStatus != null) 'sync_status': syncStatus, if (localUpdatedAt != null) 'local_updated_at': localUpdatedAt, if (serverUpdatedAt != null) 'server_updated_at': serverUpdatedAt, if (conflictPayload != null) 'conflict_payload': conflictPayload, if (userId != null) 'user_id': userId, if (username != null) 'username': username, if (realName != null) 'real_name': realName, if (phone != null) 'phone': phone, if (avatar != null) 'avatar': avatar, if (gender != null) 'gender': gender, if (age != null) 'age': age, if (refreshToken != null) 'refresh_token': refreshToken, if (email != null) 'email': email, if (birthday != null) 'birthday': birthday, if (employeeNo != null) 'employee_no': employeeNo, if (company != null) 'company': company, if (department != null) 'department': department, if (rowid != null) 'rowid': rowid, }); } UsersCompanion copyWith({ Value? syncStatus, Value? localUpdatedAt, Value? serverUpdatedAt, Value? conflictPayload, Value? userId, Value? username, Value? realName, Value? phone, Value? avatar, Value? gender, Value? age, Value? refreshToken, Value? email, Value? birthday, Value? employeeNo, Value? company, Value? department, Value? rowid, }) { return UsersCompanion( syncStatus: syncStatus ?? this.syncStatus, localUpdatedAt: localUpdatedAt ?? this.localUpdatedAt, serverUpdatedAt: serverUpdatedAt ?? this.serverUpdatedAt, conflictPayload: conflictPayload ?? this.conflictPayload, userId: userId ?? this.userId, username: username ?? this.username, realName: realName ?? this.realName, phone: phone ?? this.phone, avatar: avatar ?? this.avatar, gender: gender ?? this.gender, age: age ?? this.age, refreshToken: refreshToken ?? this.refreshToken, email: email ?? this.email, birthday: birthday ?? this.birthday, employeeNo: employeeNo ?? this.employeeNo, company: company ?? this.company, department: department ?? this.department, rowid: rowid ?? this.rowid, ); } @override Map toColumns(bool nullToAbsent) { final map = {}; if (syncStatus.present) { map['sync_status'] = Variable( $UsersTable.$convertersyncStatus.toSql(syncStatus.value), ); } if (localUpdatedAt.present) { map['local_updated_at'] = Variable(localUpdatedAt.value); } if (serverUpdatedAt.present) { map['server_updated_at'] = Variable(serverUpdatedAt.value); } if (conflictPayload.present) { map['conflict_payload'] = Variable(conflictPayload.value); } if (userId.present) { map['user_id'] = Variable(userId.value); } if (username.present) { map['username'] = Variable(username.value); } if (realName.present) { map['real_name'] = Variable(realName.value); } if (phone.present) { map['phone'] = Variable(phone.value); } if (avatar.present) { map['avatar'] = Variable(avatar.value); } if (gender.present) { map['gender'] = Variable(gender.value); } if (age.present) { map['age'] = Variable(age.value); } if (refreshToken.present) { map['refresh_token'] = Variable(refreshToken.value); } if (email.present) { map['email'] = Variable(email.value); } if (birthday.present) { map['birthday'] = Variable(birthday.value); } if (employeeNo.present) { map['employee_no'] = Variable(employeeNo.value); } if (company.present) { map['company'] = Variable(company.value); } if (department.present) { map['department'] = Variable(department.value); } if (rowid.present) { map['rowid'] = Variable(rowid.value); } return map; } @override String toString() { return (StringBuffer('UsersCompanion(') ..write('syncStatus: $syncStatus, ') ..write('localUpdatedAt: $localUpdatedAt, ') ..write('serverUpdatedAt: $serverUpdatedAt, ') ..write('conflictPayload: $conflictPayload, ') ..write('userId: $userId, ') ..write('username: $username, ') ..write('realName: $realName, ') ..write('phone: $phone, ') ..write('avatar: $avatar, ') ..write('gender: $gender, ') ..write('age: $age, ') ..write('refreshToken: $refreshToken, ') ..write('email: $email, ') ..write('birthday: $birthday, ') ..write('employeeNo: $employeeNo, ') ..write('company: $company, ') ..write('department: $department, ') ..write('rowid: $rowid') ..write(')')) .toString(); } } class $ErrorLogsTable extends ErrorLogs with TableInfo<$ErrorLogsTable, ErrorLogRow> { @override final GeneratedDatabase attachedDatabase; final String? _alias; $ErrorLogsTable(this.attachedDatabase, [this._alias]); static const VerificationMeta _idMeta = const VerificationMeta('id'); @override late final GeneratedColumn id = GeneratedColumn( 'id', aliasedName, false, hasAutoIncrement: true, type: DriftSqlType.int, requiredDuringInsert: false, defaultConstraints: GeneratedColumn.constraintIsAlways( 'PRIMARY KEY AUTOINCREMENT', ), ); static const VerificationMeta _kindMeta = const VerificationMeta('kind'); @override late final GeneratedColumn kind = GeneratedColumn( 'kind', aliasedName, false, type: DriftSqlType.string, requiredDuringInsert: true, ); static const VerificationMeta _messageMeta = const VerificationMeta( 'message', ); @override late final GeneratedColumn message = GeneratedColumn( 'message', aliasedName, false, type: DriftSqlType.string, requiredDuringInsert: true, ); static const VerificationMeta _displayMessageMeta = const VerificationMeta( 'displayMessage', ); @override late final GeneratedColumn displayMessage = GeneratedColumn( 'display_message', aliasedName, false, type: DriftSqlType.string, requiredDuringInsert: true, ); static const VerificationMeta _codeMeta = const VerificationMeta('code'); @override late final GeneratedColumn code = GeneratedColumn( 'code', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _statusCodeMeta = const VerificationMeta( 'statusCode', ); @override late final GeneratedColumn statusCode = GeneratedColumn( 'status_code', aliasedName, true, type: DriftSqlType.int, requiredDuringInsert: false, ); static const VerificationMeta _occurredAtMeta = const VerificationMeta( 'occurredAt', ); @override late final GeneratedColumn occurredAt = GeneratedColumn( 'occurred_at', aliasedName, false, type: DriftSqlType.dateTime, requiredDuringInsert: true, ); static const VerificationMeta _reportedMeta = const VerificationMeta( 'reported', ); @override late final GeneratedColumn reported = GeneratedColumn( 'reported', aliasedName, false, type: DriftSqlType.bool, requiredDuringInsert: false, defaultConstraints: GeneratedColumn.constraintIsAlways( 'CHECK ("reported" IN (0, 1))', ), defaultValue: const Constant(false), ); static const VerificationMeta _deviceModelMeta = const VerificationMeta( 'deviceModel', ); @override late final GeneratedColumn deviceModel = GeneratedColumn( 'device_model', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _osVersionMeta = const VerificationMeta( 'osVersion', ); @override late final GeneratedColumn osVersion = GeneratedColumn( 'os_version', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _appVersionMeta = const VerificationMeta( 'appVersion', ); @override late final GeneratedColumn appVersion = GeneratedColumn( 'app_version', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); static const VerificationMeta _appBuildMeta = const VerificationMeta( 'appBuild', ); @override late final GeneratedColumn appBuild = GeneratedColumn( 'app_build', aliasedName, true, type: DriftSqlType.string, requiredDuringInsert: false, ); @override List get $columns => [ id, kind, message, displayMessage, code, statusCode, occurredAt, reported, deviceModel, osVersion, appVersion, appBuild, ]; @override String get aliasedName => _alias ?? actualTableName; @override String get actualTableName => $name; static const String $name = 'error_logs'; @override VerificationContext validateIntegrity( Insertable 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('kind')) { context.handle( _kindMeta, kind.isAcceptableOrUnknown(data['kind']!, _kindMeta), ); } else if (isInserting) { context.missing(_kindMeta); } if (data.containsKey('message')) { context.handle( _messageMeta, message.isAcceptableOrUnknown(data['message']!, _messageMeta), ); } else if (isInserting) { context.missing(_messageMeta); } if (data.containsKey('display_message')) { context.handle( _displayMessageMeta, displayMessage.isAcceptableOrUnknown( data['display_message']!, _displayMessageMeta, ), ); } else if (isInserting) { context.missing(_displayMessageMeta); } if (data.containsKey('code')) { context.handle( _codeMeta, code.isAcceptableOrUnknown(data['code']!, _codeMeta), ); } if (data.containsKey('status_code')) { context.handle( _statusCodeMeta, statusCode.isAcceptableOrUnknown(data['status_code']!, _statusCodeMeta), ); } if (data.containsKey('occurred_at')) { context.handle( _occurredAtMeta, occurredAt.isAcceptableOrUnknown(data['occurred_at']!, _occurredAtMeta), ); } else if (isInserting) { context.missing(_occurredAtMeta); } if (data.containsKey('reported')) { context.handle( _reportedMeta, reported.isAcceptableOrUnknown(data['reported']!, _reportedMeta), ); } if (data.containsKey('device_model')) { context.handle( _deviceModelMeta, deviceModel.isAcceptableOrUnknown( data['device_model']!, _deviceModelMeta, ), ); } if (data.containsKey('os_version')) { context.handle( _osVersionMeta, osVersion.isAcceptableOrUnknown(data['os_version']!, _osVersionMeta), ); } if (data.containsKey('app_version')) { context.handle( _appVersionMeta, appVersion.isAcceptableOrUnknown(data['app_version']!, _appVersionMeta), ); } if (data.containsKey('app_build')) { context.handle( _appBuildMeta, appBuild.isAcceptableOrUnknown(data['app_build']!, _appBuildMeta), ); } return context; } @override Set get $primaryKey => {id}; @override ErrorLogRow map(Map data, {String? tablePrefix}) { final effectivePrefix = tablePrefix != null ? '$tablePrefix.' : ''; return ErrorLogRow( id: attachedDatabase.typeMapping.read( DriftSqlType.int, data['${effectivePrefix}id'], )!, kind: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}kind'], )!, message: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}message'], )!, displayMessage: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}display_message'], )!, code: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}code'], ), statusCode: attachedDatabase.typeMapping.read( DriftSqlType.int, data['${effectivePrefix}status_code'], ), occurredAt: attachedDatabase.typeMapping.read( DriftSqlType.dateTime, data['${effectivePrefix}occurred_at'], )!, reported: attachedDatabase.typeMapping.read( DriftSqlType.bool, data['${effectivePrefix}reported'], )!, deviceModel: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}device_model'], ), osVersion: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}os_version'], ), appVersion: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}app_version'], ), appBuild: attachedDatabase.typeMapping.read( DriftSqlType.string, data['${effectivePrefix}app_build'], ), ); } @override $ErrorLogsTable createAlias(String alias) { return $ErrorLogsTable(attachedDatabase, alias); } } class ErrorLogRow extends DataClass implements Insertable { final int id; final String kind; final String message; final String displayMessage; final String? code; final int? statusCode; final DateTime occurredAt; final bool reported; final String? deviceModel; final String? osVersion; final String? appVersion; final String? appBuild; const ErrorLogRow({ required this.id, required this.kind, required this.message, required this.displayMessage, this.code, this.statusCode, required this.occurredAt, required this.reported, this.deviceModel, this.osVersion, this.appVersion, this.appBuild, }); @override Map toColumns(bool nullToAbsent) { final map = {}; map['id'] = Variable(id); map['kind'] = Variable(kind); map['message'] = Variable(message); map['display_message'] = Variable(displayMessage); if (!nullToAbsent || code != null) { map['code'] = Variable(code); } if (!nullToAbsent || statusCode != null) { map['status_code'] = Variable(statusCode); } map['occurred_at'] = Variable(occurredAt); map['reported'] = Variable(reported); if (!nullToAbsent || deviceModel != null) { map['device_model'] = Variable(deviceModel); } if (!nullToAbsent || osVersion != null) { map['os_version'] = Variable(osVersion); } if (!nullToAbsent || appVersion != null) { map['app_version'] = Variable(appVersion); } if (!nullToAbsent || appBuild != null) { map['app_build'] = Variable(appBuild); } return map; } ErrorLogsCompanion toCompanion(bool nullToAbsent) { return ErrorLogsCompanion( id: Value(id), kind: Value(kind), message: Value(message), displayMessage: Value(displayMessage), code: code == null && nullToAbsent ? const Value.absent() : Value(code), statusCode: statusCode == null && nullToAbsent ? const Value.absent() : Value(statusCode), occurredAt: Value(occurredAt), reported: Value(reported), deviceModel: deviceModel == null && nullToAbsent ? const Value.absent() : Value(deviceModel), osVersion: osVersion == null && nullToAbsent ? const Value.absent() : Value(osVersion), appVersion: appVersion == null && nullToAbsent ? const Value.absent() : Value(appVersion), appBuild: appBuild == null && nullToAbsent ? const Value.absent() : Value(appBuild), ); } factory ErrorLogRow.fromJson( Map json, { ValueSerializer? serializer, }) { serializer ??= driftRuntimeOptions.defaultSerializer; return ErrorLogRow( id: serializer.fromJson(json['id']), kind: serializer.fromJson(json['kind']), message: serializer.fromJson(json['message']), displayMessage: serializer.fromJson(json['displayMessage']), code: serializer.fromJson(json['code']), statusCode: serializer.fromJson(json['statusCode']), occurredAt: serializer.fromJson(json['occurredAt']), reported: serializer.fromJson(json['reported']), deviceModel: serializer.fromJson(json['deviceModel']), osVersion: serializer.fromJson(json['osVersion']), appVersion: serializer.fromJson(json['appVersion']), appBuild: serializer.fromJson(json['appBuild']), ); } @override Map toJson({ValueSerializer? serializer}) { serializer ??= driftRuntimeOptions.defaultSerializer; return { 'id': serializer.toJson(id), 'kind': serializer.toJson(kind), 'message': serializer.toJson(message), 'displayMessage': serializer.toJson(displayMessage), 'code': serializer.toJson(code), 'statusCode': serializer.toJson(statusCode), 'occurredAt': serializer.toJson(occurredAt), 'reported': serializer.toJson(reported), 'deviceModel': serializer.toJson(deviceModel), 'osVersion': serializer.toJson(osVersion), 'appVersion': serializer.toJson(appVersion), 'appBuild': serializer.toJson(appBuild), }; } ErrorLogRow copyWith({ int? id, String? kind, String? message, String? displayMessage, Value code = const Value.absent(), Value statusCode = const Value.absent(), DateTime? occurredAt, bool? reported, Value deviceModel = const Value.absent(), Value osVersion = const Value.absent(), Value appVersion = const Value.absent(), Value appBuild = const Value.absent(), }) => ErrorLogRow( id: id ?? this.id, kind: kind ?? this.kind, message: message ?? this.message, displayMessage: displayMessage ?? this.displayMessage, code: code.present ? code.value : this.code, statusCode: statusCode.present ? statusCode.value : this.statusCode, occurredAt: occurredAt ?? this.occurredAt, reported: reported ?? this.reported, deviceModel: deviceModel.present ? deviceModel.value : this.deviceModel, osVersion: osVersion.present ? osVersion.value : this.osVersion, appVersion: appVersion.present ? appVersion.value : this.appVersion, appBuild: appBuild.present ? appBuild.value : this.appBuild, ); ErrorLogRow copyWithCompanion(ErrorLogsCompanion data) { return ErrorLogRow( id: data.id.present ? data.id.value : this.id, kind: data.kind.present ? data.kind.value : this.kind, message: data.message.present ? data.message.value : this.message, displayMessage: data.displayMessage.present ? data.displayMessage.value : this.displayMessage, code: data.code.present ? data.code.value : this.code, statusCode: data.statusCode.present ? data.statusCode.value : this.statusCode, occurredAt: data.occurredAt.present ? data.occurredAt.value : this.occurredAt, reported: data.reported.present ? data.reported.value : this.reported, deviceModel: data.deviceModel.present ? data.deviceModel.value : this.deviceModel, osVersion: data.osVersion.present ? data.osVersion.value : this.osVersion, appVersion: data.appVersion.present ? data.appVersion.value : this.appVersion, appBuild: data.appBuild.present ? data.appBuild.value : this.appBuild, ); } @override String toString() { return (StringBuffer('ErrorLogRow(') ..write('id: $id, ') ..write('kind: $kind, ') ..write('message: $message, ') ..write('displayMessage: $displayMessage, ') ..write('code: $code, ') ..write('statusCode: $statusCode, ') ..write('occurredAt: $occurredAt, ') ..write('reported: $reported, ') ..write('deviceModel: $deviceModel, ') ..write('osVersion: $osVersion, ') ..write('appVersion: $appVersion, ') ..write('appBuild: $appBuild') ..write(')')) .toString(); } @override int get hashCode => Object.hash( id, kind, message, displayMessage, code, statusCode, occurredAt, reported, deviceModel, osVersion, appVersion, appBuild, ); @override bool operator ==(Object other) => identical(this, other) || (other is ErrorLogRow && other.id == this.id && other.kind == this.kind && other.message == this.message && other.displayMessage == this.displayMessage && other.code == this.code && other.statusCode == this.statusCode && other.occurredAt == this.occurredAt && other.reported == this.reported && other.deviceModel == this.deviceModel && other.osVersion == this.osVersion && other.appVersion == this.appVersion && other.appBuild == this.appBuild); } class ErrorLogsCompanion extends UpdateCompanion { final Value id; final Value kind; final Value message; final Value displayMessage; final Value code; final Value statusCode; final Value occurredAt; final Value reported; final Value deviceModel; final Value osVersion; final Value appVersion; final Value appBuild; const ErrorLogsCompanion({ this.id = const Value.absent(), this.kind = const Value.absent(), this.message = const Value.absent(), this.displayMessage = const Value.absent(), this.code = const Value.absent(), this.statusCode = const Value.absent(), this.occurredAt = const Value.absent(), this.reported = const Value.absent(), this.deviceModel = const Value.absent(), this.osVersion = const Value.absent(), this.appVersion = const Value.absent(), this.appBuild = const Value.absent(), }); ErrorLogsCompanion.insert({ this.id = const Value.absent(), required String kind, required String message, required String displayMessage, this.code = const Value.absent(), this.statusCode = const Value.absent(), required DateTime occurredAt, this.reported = const Value.absent(), this.deviceModel = const Value.absent(), this.osVersion = const Value.absent(), this.appVersion = const Value.absent(), this.appBuild = const Value.absent(), }) : kind = Value(kind), message = Value(message), displayMessage = Value(displayMessage), occurredAt = Value(occurredAt); static Insertable custom({ Expression? id, Expression? kind, Expression? message, Expression? displayMessage, Expression? code, Expression? statusCode, Expression? occurredAt, Expression? reported, Expression? deviceModel, Expression? osVersion, Expression? appVersion, Expression? appBuild, }) { return RawValuesInsertable({ if (id != null) 'id': id, if (kind != null) 'kind': kind, if (message != null) 'message': message, if (displayMessage != null) 'display_message': displayMessage, if (code != null) 'code': code, if (statusCode != null) 'status_code': statusCode, if (occurredAt != null) 'occurred_at': occurredAt, if (reported != null) 'reported': reported, if (deviceModel != null) 'device_model': deviceModel, if (osVersion != null) 'os_version': osVersion, if (appVersion != null) 'app_version': appVersion, if (appBuild != null) 'app_build': appBuild, }); } ErrorLogsCompanion copyWith({ Value? id, Value? kind, Value? message, Value? displayMessage, Value? code, Value? statusCode, Value? occurredAt, Value? reported, Value? deviceModel, Value? osVersion, Value? appVersion, Value? appBuild, }) { return ErrorLogsCompanion( id: id ?? this.id, kind: kind ?? this.kind, message: message ?? this.message, displayMessage: displayMessage ?? this.displayMessage, code: code ?? this.code, statusCode: statusCode ?? this.statusCode, occurredAt: occurredAt ?? this.occurredAt, reported: reported ?? this.reported, deviceModel: deviceModel ?? this.deviceModel, osVersion: osVersion ?? this.osVersion, appVersion: appVersion ?? this.appVersion, appBuild: appBuild ?? this.appBuild, ); } @override Map toColumns(bool nullToAbsent) { final map = {}; if (id.present) { map['id'] = Variable(id.value); } if (kind.present) { map['kind'] = Variable(kind.value); } if (message.present) { map['message'] = Variable(message.value); } if (displayMessage.present) { map['display_message'] = Variable(displayMessage.value); } if (code.present) { map['code'] = Variable(code.value); } if (statusCode.present) { map['status_code'] = Variable(statusCode.value); } if (occurredAt.present) { map['occurred_at'] = Variable(occurredAt.value); } if (reported.present) { map['reported'] = Variable(reported.value); } if (deviceModel.present) { map['device_model'] = Variable(deviceModel.value); } if (osVersion.present) { map['os_version'] = Variable(osVersion.value); } if (appVersion.present) { map['app_version'] = Variable(appVersion.value); } if (appBuild.present) { map['app_build'] = Variable(appBuild.value); } return map; } @override String toString() { return (StringBuffer('ErrorLogsCompanion(') ..write('id: $id, ') ..write('kind: $kind, ') ..write('message: $message, ') ..write('displayMessage: $displayMessage, ') ..write('code: $code, ') ..write('statusCode: $statusCode, ') ..write('occurredAt: $occurredAt, ') ..write('reported: $reported, ') ..write('deviceModel: $deviceModel, ') ..write('osVersion: $osVersion, ') ..write('appVersion: $appVersion, ') ..write('appBuild: $appBuild') ..write(')')) .toString(); } } abstract class _$AppDatabase extends GeneratedDatabase { _$AppDatabase(QueryExecutor e) : super(e); $AppDatabaseManager get managers => $AppDatabaseManager(this); late final $UsersTable users = $UsersTable(this); late final $ErrorLogsTable errorLogs = $ErrorLogsTable(this); @override Iterable> get allTables => allSchemaEntities.whereType>(); @override List get allSchemaEntities => [users, errorLogs]; } typedef $$UsersTableCreateCompanionBuilder = UsersCompanion Function({ Value syncStatus, Value localUpdatedAt, Value serverUpdatedAt, Value conflictPayload, required String userId, Value username, Value realName, Value phone, Value avatar, Value gender, Value age, Value refreshToken, Value email, Value birthday, Value employeeNo, Value company, Value department, Value rowid, }); typedef $$UsersTableUpdateCompanionBuilder = UsersCompanion Function({ Value syncStatus, Value localUpdatedAt, Value serverUpdatedAt, Value conflictPayload, Value userId, Value username, Value realName, Value phone, Value avatar, Value gender, Value age, Value refreshToken, Value email, Value birthday, Value employeeNo, Value company, Value department, Value rowid, }); class $$UsersTableFilterComposer extends Composer<_$AppDatabase, $UsersTable> { $$UsersTableFilterComposer({ required super.$db, required super.$table, super.joinBuilder, super.$addJoinBuilderToRootComposer, super.$removeJoinBuilderFromRootComposer, }); ColumnWithTypeConverterFilters get syncStatus => $composableBuilder( column: $table.syncStatus, builder: (column) => ColumnWithTypeConverterFilters(column), ); ColumnFilters get localUpdatedAt => $composableBuilder( column: $table.localUpdatedAt, builder: (column) => ColumnFilters(column), ); ColumnFilters get serverUpdatedAt => $composableBuilder( column: $table.serverUpdatedAt, builder: (column) => ColumnFilters(column), ); ColumnFilters get conflictPayload => $composableBuilder( column: $table.conflictPayload, builder: (column) => ColumnFilters(column), ); ColumnFilters get userId => $composableBuilder( column: $table.userId, builder: (column) => ColumnFilters(column), ); ColumnFilters get username => $composableBuilder( column: $table.username, builder: (column) => ColumnFilters(column), ); ColumnFilters get realName => $composableBuilder( column: $table.realName, builder: (column) => ColumnFilters(column), ); ColumnFilters get phone => $composableBuilder( column: $table.phone, builder: (column) => ColumnFilters(column), ); ColumnFilters get avatar => $composableBuilder( column: $table.avatar, builder: (column) => ColumnFilters(column), ); ColumnFilters get gender => $composableBuilder( column: $table.gender, builder: (column) => ColumnFilters(column), ); ColumnFilters get age => $composableBuilder( column: $table.age, builder: (column) => ColumnFilters(column), ); ColumnFilters get refreshToken => $composableBuilder( column: $table.refreshToken, builder: (column) => ColumnFilters(column), ); ColumnFilters get email => $composableBuilder( column: $table.email, builder: (column) => ColumnFilters(column), ); ColumnFilters get birthday => $composableBuilder( column: $table.birthday, builder: (column) => ColumnFilters(column), ); ColumnFilters get employeeNo => $composableBuilder( column: $table.employeeNo, builder: (column) => ColumnFilters(column), ); ColumnFilters get company => $composableBuilder( column: $table.company, builder: (column) => ColumnFilters(column), ); ColumnFilters get department => $composableBuilder( column: $table.department, builder: (column) => ColumnFilters(column), ); } class $$UsersTableOrderingComposer extends Composer<_$AppDatabase, $UsersTable> { $$UsersTableOrderingComposer({ required super.$db, required super.$table, super.joinBuilder, super.$addJoinBuilderToRootComposer, super.$removeJoinBuilderFromRootComposer, }); ColumnOrderings get syncStatus => $composableBuilder( column: $table.syncStatus, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get localUpdatedAt => $composableBuilder( column: $table.localUpdatedAt, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get serverUpdatedAt => $composableBuilder( column: $table.serverUpdatedAt, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get conflictPayload => $composableBuilder( column: $table.conflictPayload, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get userId => $composableBuilder( column: $table.userId, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get username => $composableBuilder( column: $table.username, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get realName => $composableBuilder( column: $table.realName, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get phone => $composableBuilder( column: $table.phone, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get avatar => $composableBuilder( column: $table.avatar, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get gender => $composableBuilder( column: $table.gender, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get age => $composableBuilder( column: $table.age, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get refreshToken => $composableBuilder( column: $table.refreshToken, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get email => $composableBuilder( column: $table.email, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get birthday => $composableBuilder( column: $table.birthday, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get employeeNo => $composableBuilder( column: $table.employeeNo, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get company => $composableBuilder( column: $table.company, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get department => $composableBuilder( column: $table.department, builder: (column) => ColumnOrderings(column), ); } class $$UsersTableAnnotationComposer extends Composer<_$AppDatabase, $UsersTable> { $$UsersTableAnnotationComposer({ required super.$db, required super.$table, super.joinBuilder, super.$addJoinBuilderToRootComposer, super.$removeJoinBuilderFromRootComposer, }); GeneratedColumnWithTypeConverter get syncStatus => $composableBuilder( column: $table.syncStatus, builder: (column) => column, ); GeneratedColumn get localUpdatedAt => $composableBuilder( column: $table.localUpdatedAt, builder: (column) => column, ); GeneratedColumn get serverUpdatedAt => $composableBuilder( column: $table.serverUpdatedAt, builder: (column) => column, ); GeneratedColumn get conflictPayload => $composableBuilder( column: $table.conflictPayload, builder: (column) => column, ); GeneratedColumn get userId => $composableBuilder(column: $table.userId, builder: (column) => column); GeneratedColumn get username => $composableBuilder(column: $table.username, builder: (column) => column); GeneratedColumn get realName => $composableBuilder(column: $table.realName, builder: (column) => column); GeneratedColumn get phone => $composableBuilder(column: $table.phone, builder: (column) => column); GeneratedColumn get avatar => $composableBuilder(column: $table.avatar, builder: (column) => column); GeneratedColumn get gender => $composableBuilder(column: $table.gender, builder: (column) => column); GeneratedColumn get age => $composableBuilder(column: $table.age, builder: (column) => column); GeneratedColumn get refreshToken => $composableBuilder( column: $table.refreshToken, builder: (column) => column, ); GeneratedColumn get email => $composableBuilder(column: $table.email, builder: (column) => column); GeneratedColumn get birthday => $composableBuilder(column: $table.birthday, builder: (column) => column); GeneratedColumn get employeeNo => $composableBuilder( column: $table.employeeNo, builder: (column) => column, ); GeneratedColumn get company => $composableBuilder(column: $table.company, builder: (column) => column); GeneratedColumn get department => $composableBuilder( column: $table.department, builder: (column) => column, ); } class $$UsersTableTableManager extends RootTableManager< _$AppDatabase, $UsersTable, UserRow, $$UsersTableFilterComposer, $$UsersTableOrderingComposer, $$UsersTableAnnotationComposer, $$UsersTableCreateCompanionBuilder, $$UsersTableUpdateCompanionBuilder, (UserRow, BaseReferences<_$AppDatabase, $UsersTable, UserRow>), UserRow, PrefetchHooks Function() > { $$UsersTableTableManager(_$AppDatabase db, $UsersTable table) : super( TableManagerState( db: db, table: table, createFilteringComposer: () => $$UsersTableFilterComposer($db: db, $table: table), createOrderingComposer: () => $$UsersTableOrderingComposer($db: db, $table: table), createComputedFieldComposer: () => $$UsersTableAnnotationComposer($db: db, $table: table), updateCompanionCallback: ({ Value syncStatus = const Value.absent(), Value localUpdatedAt = const Value.absent(), Value serverUpdatedAt = const Value.absent(), Value conflictPayload = const Value.absent(), Value userId = const Value.absent(), Value username = const Value.absent(), Value realName = const Value.absent(), Value phone = const Value.absent(), Value avatar = const Value.absent(), Value gender = const Value.absent(), Value age = const Value.absent(), Value refreshToken = const Value.absent(), Value email = const Value.absent(), Value birthday = const Value.absent(), Value employeeNo = const Value.absent(), Value company = const Value.absent(), Value department = const Value.absent(), Value rowid = const Value.absent(), }) => UsersCompanion( syncStatus: syncStatus, localUpdatedAt: localUpdatedAt, serverUpdatedAt: serverUpdatedAt, conflictPayload: conflictPayload, userId: userId, username: username, realName: realName, phone: phone, avatar: avatar, gender: gender, age: age, refreshToken: refreshToken, email: email, birthday: birthday, employeeNo: employeeNo, company: company, department: department, rowid: rowid, ), createCompanionCallback: ({ Value syncStatus = const Value.absent(), Value localUpdatedAt = const Value.absent(), Value serverUpdatedAt = const Value.absent(), Value conflictPayload = const Value.absent(), required String userId, Value username = const Value.absent(), Value realName = const Value.absent(), Value phone = const Value.absent(), Value avatar = const Value.absent(), Value gender = const Value.absent(), Value age = const Value.absent(), Value refreshToken = const Value.absent(), Value email = const Value.absent(), Value birthday = const Value.absent(), Value employeeNo = const Value.absent(), Value company = const Value.absent(), Value department = const Value.absent(), Value rowid = const Value.absent(), }) => UsersCompanion.insert( syncStatus: syncStatus, localUpdatedAt: localUpdatedAt, serverUpdatedAt: serverUpdatedAt, conflictPayload: conflictPayload, userId: userId, username: username, realName: realName, phone: phone, avatar: avatar, gender: gender, age: age, refreshToken: refreshToken, email: email, birthday: birthday, employeeNo: employeeNo, company: company, department: department, rowid: rowid, ), withReferenceMapper: (p0) => p0 .map((e) => (e.readTable(table), BaseReferences(db, table, e))) .toList(), prefetchHooksCallback: null, ), ); } typedef $$UsersTableProcessedTableManager = ProcessedTableManager< _$AppDatabase, $UsersTable, UserRow, $$UsersTableFilterComposer, $$UsersTableOrderingComposer, $$UsersTableAnnotationComposer, $$UsersTableCreateCompanionBuilder, $$UsersTableUpdateCompanionBuilder, (UserRow, BaseReferences<_$AppDatabase, $UsersTable, UserRow>), UserRow, PrefetchHooks Function() >; typedef $$ErrorLogsTableCreateCompanionBuilder = ErrorLogsCompanion Function({ Value id, required String kind, required String message, required String displayMessage, Value code, Value statusCode, required DateTime occurredAt, Value reported, Value deviceModel, Value osVersion, Value appVersion, Value appBuild, }); typedef $$ErrorLogsTableUpdateCompanionBuilder = ErrorLogsCompanion Function({ Value id, Value kind, Value message, Value displayMessage, Value code, Value statusCode, Value occurredAt, Value reported, Value deviceModel, Value osVersion, Value appVersion, Value appBuild, }); class $$ErrorLogsTableFilterComposer extends Composer<_$AppDatabase, $ErrorLogsTable> { $$ErrorLogsTableFilterComposer({ required super.$db, required super.$table, super.joinBuilder, super.$addJoinBuilderToRootComposer, super.$removeJoinBuilderFromRootComposer, }); ColumnFilters get id => $composableBuilder( column: $table.id, builder: (column) => ColumnFilters(column), ); ColumnFilters get kind => $composableBuilder( column: $table.kind, builder: (column) => ColumnFilters(column), ); ColumnFilters get message => $composableBuilder( column: $table.message, builder: (column) => ColumnFilters(column), ); ColumnFilters get displayMessage => $composableBuilder( column: $table.displayMessage, builder: (column) => ColumnFilters(column), ); ColumnFilters get code => $composableBuilder( column: $table.code, builder: (column) => ColumnFilters(column), ); ColumnFilters get statusCode => $composableBuilder( column: $table.statusCode, builder: (column) => ColumnFilters(column), ); ColumnFilters get occurredAt => $composableBuilder( column: $table.occurredAt, builder: (column) => ColumnFilters(column), ); ColumnFilters get reported => $composableBuilder( column: $table.reported, builder: (column) => ColumnFilters(column), ); ColumnFilters get deviceModel => $composableBuilder( column: $table.deviceModel, builder: (column) => ColumnFilters(column), ); ColumnFilters get osVersion => $composableBuilder( column: $table.osVersion, builder: (column) => ColumnFilters(column), ); ColumnFilters get appVersion => $composableBuilder( column: $table.appVersion, builder: (column) => ColumnFilters(column), ); ColumnFilters get appBuild => $composableBuilder( column: $table.appBuild, builder: (column) => ColumnFilters(column), ); } class $$ErrorLogsTableOrderingComposer extends Composer<_$AppDatabase, $ErrorLogsTable> { $$ErrorLogsTableOrderingComposer({ required super.$db, required super.$table, super.joinBuilder, super.$addJoinBuilderToRootComposer, super.$removeJoinBuilderFromRootComposer, }); ColumnOrderings get id => $composableBuilder( column: $table.id, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get kind => $composableBuilder( column: $table.kind, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get message => $composableBuilder( column: $table.message, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get displayMessage => $composableBuilder( column: $table.displayMessage, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get code => $composableBuilder( column: $table.code, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get statusCode => $composableBuilder( column: $table.statusCode, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get occurredAt => $composableBuilder( column: $table.occurredAt, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get reported => $composableBuilder( column: $table.reported, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get deviceModel => $composableBuilder( column: $table.deviceModel, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get osVersion => $composableBuilder( column: $table.osVersion, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get appVersion => $composableBuilder( column: $table.appVersion, builder: (column) => ColumnOrderings(column), ); ColumnOrderings get appBuild => $composableBuilder( column: $table.appBuild, builder: (column) => ColumnOrderings(column), ); } class $$ErrorLogsTableAnnotationComposer extends Composer<_$AppDatabase, $ErrorLogsTable> { $$ErrorLogsTableAnnotationComposer({ required super.$db, required super.$table, super.joinBuilder, super.$addJoinBuilderToRootComposer, super.$removeJoinBuilderFromRootComposer, }); GeneratedColumn get id => $composableBuilder(column: $table.id, builder: (column) => column); GeneratedColumn get kind => $composableBuilder(column: $table.kind, builder: (column) => column); GeneratedColumn get message => $composableBuilder(column: $table.message, builder: (column) => column); GeneratedColumn get displayMessage => $composableBuilder( column: $table.displayMessage, builder: (column) => column, ); GeneratedColumn get code => $composableBuilder(column: $table.code, builder: (column) => column); GeneratedColumn get statusCode => $composableBuilder( column: $table.statusCode, builder: (column) => column, ); GeneratedColumn get occurredAt => $composableBuilder( column: $table.occurredAt, builder: (column) => column, ); GeneratedColumn get reported => $composableBuilder(column: $table.reported, builder: (column) => column); GeneratedColumn get deviceModel => $composableBuilder( column: $table.deviceModel, builder: (column) => column, ); GeneratedColumn get osVersion => $composableBuilder(column: $table.osVersion, builder: (column) => column); GeneratedColumn get appVersion => $composableBuilder( column: $table.appVersion, builder: (column) => column, ); GeneratedColumn get appBuild => $composableBuilder(column: $table.appBuild, builder: (column) => column); } class $$ErrorLogsTableTableManager extends RootTableManager< _$AppDatabase, $ErrorLogsTable, ErrorLogRow, $$ErrorLogsTableFilterComposer, $$ErrorLogsTableOrderingComposer, $$ErrorLogsTableAnnotationComposer, $$ErrorLogsTableCreateCompanionBuilder, $$ErrorLogsTableUpdateCompanionBuilder, ( ErrorLogRow, BaseReferences<_$AppDatabase, $ErrorLogsTable, ErrorLogRow>, ), ErrorLogRow, PrefetchHooks Function() > { $$ErrorLogsTableTableManager(_$AppDatabase db, $ErrorLogsTable table) : super( TableManagerState( db: db, table: table, createFilteringComposer: () => $$ErrorLogsTableFilterComposer($db: db, $table: table), createOrderingComposer: () => $$ErrorLogsTableOrderingComposer($db: db, $table: table), createComputedFieldComposer: () => $$ErrorLogsTableAnnotationComposer($db: db, $table: table), updateCompanionCallback: ({ Value id = const Value.absent(), Value kind = const Value.absent(), Value message = const Value.absent(), Value displayMessage = const Value.absent(), Value code = const Value.absent(), Value statusCode = const Value.absent(), Value occurredAt = const Value.absent(), Value reported = const Value.absent(), Value deviceModel = const Value.absent(), Value osVersion = const Value.absent(), Value appVersion = const Value.absent(), Value appBuild = const Value.absent(), }) => ErrorLogsCompanion( id: id, kind: kind, message: message, displayMessage: displayMessage, code: code, statusCode: statusCode, occurredAt: occurredAt, reported: reported, deviceModel: deviceModel, osVersion: osVersion, appVersion: appVersion, appBuild: appBuild, ), createCompanionCallback: ({ Value id = const Value.absent(), required String kind, required String message, required String displayMessage, Value code = const Value.absent(), Value statusCode = const Value.absent(), required DateTime occurredAt, Value reported = const Value.absent(), Value deviceModel = const Value.absent(), Value osVersion = const Value.absent(), Value appVersion = const Value.absent(), Value appBuild = const Value.absent(), }) => ErrorLogsCompanion.insert( id: id, kind: kind, message: message, displayMessage: displayMessage, code: code, statusCode: statusCode, occurredAt: occurredAt, reported: reported, deviceModel: deviceModel, osVersion: osVersion, appVersion: appVersion, appBuild: appBuild, ), withReferenceMapper: (p0) => p0 .map((e) => (e.readTable(table), BaseReferences(db, table, e))) .toList(), prefetchHooksCallback: null, ), ); } typedef $$ErrorLogsTableProcessedTableManager = ProcessedTableManager< _$AppDatabase, $ErrorLogsTable, ErrorLogRow, $$ErrorLogsTableFilterComposer, $$ErrorLogsTableOrderingComposer, $$ErrorLogsTableAnnotationComposer, $$ErrorLogsTableCreateCompanionBuilder, $$ErrorLogsTableUpdateCompanionBuilder, ( ErrorLogRow, BaseReferences<_$AppDatabase, $ErrorLogsTable, ErrorLogRow>, ), ErrorLogRow, PrefetchHooks Function() >; class $AppDatabaseManager { final _$AppDatabase _db; $AppDatabaseManager(this._db); $$UsersTableTableManager get users => $$UsersTableTableManager(_db, _db.users); $$ErrorLogsTableTableManager get errorLogs => $$ErrorLogsTableTableManager(_db, _db.errorLogs); } // ************************************************************************** // RiverpodGenerator // ************************************************************************** // GENERATED CODE - DO NOT MODIFY BY HAND // ignore_for_file: type=lint, type=warning /// 全局 AppDatabase provider。在 main.dart 通过 override 注入实例。 @ProviderFor(appDatabase) final appDatabaseProvider = AppDatabaseProvider._(); /// 全局 AppDatabase provider。在 main.dart 通过 override 注入实例。 final class AppDatabaseProvider extends $FunctionalProvider with $Provider { /// 全局 AppDatabase provider。在 main.dart 通过 override 注入实例。 AppDatabaseProvider._() : super( from: null, argument: null, retry: null, name: r'appDatabaseProvider', isAutoDispose: false, dependencies: null, $allTransitiveDependencies: null, ); @override String debugGetCreateSourceHash() => _$appDatabaseHash(); @$internal @override $ProviderElement $createElement($ProviderPointer pointer) => $ProviderElement(pointer); @override AppDatabase create(Ref ref) { return appDatabase(ref); } /// {@macro riverpod.override_with_value} Override overrideWithValue(AppDatabase value) { return $ProviderOverride( origin: this, providerOverride: $SyncValueProvider(value), ); } } String _$appDatabaseHash() => r'67944daf71969f5618c4fa9cdd60a2d1db056dd5';