stack_wallet/lib/models/isar/models/encrypted_string_value.g.dart
2023-01-10 10:02:54 -06:00

758 lines
22 KiB
Dart

// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'encrypted_string_value.dart';
// **************************************************************************
// IsarCollectionGenerator
// **************************************************************************
// coverage:ignore-file
// ignore_for_file: duplicate_ignore, non_constant_identifier_names, constant_identifier_names, invalid_use_of_protected_member, unnecessary_cast, prefer_const_constructors, lines_longer_than_80_chars, require_trailing_commas, inference_failure_on_function_invocation, unnecessary_parenthesis, unnecessary_raw_strings, unnecessary_null_checks, join_return_with_assignment, prefer_final_locals, avoid_js_rounded_ints, avoid_positional_boolean_parameters
extension GetEncryptedStringValueCollection on Isar {
IsarCollection<EncryptedStringValue> get encryptedStringValues =>
this.collection();
}
const EncryptedStringValueSchema = CollectionSchema(
name: r'EncryptedStringValue',
id: 4826543019451092626,
properties: {
r'key': PropertySchema(
id: 0,
name: r'key',
type: IsarType.string,
),
r'value': PropertySchema(
id: 1,
name: r'value',
type: IsarType.string,
)
},
estimateSize: _encryptedStringValueEstimateSize,
serialize: _encryptedStringValueSerialize,
deserialize: _encryptedStringValueDeserialize,
deserializeProp: _encryptedStringValueDeserializeProp,
idName: r'id',
indexes: {
r'key': IndexSchema(
id: -4906094122524121629,
name: r'key',
unique: true,
replace: true,
properties: [
IndexPropertySchema(
name: r'key',
type: IndexType.hash,
caseSensitive: true,
)
],
)
},
links: {},
embeddedSchemas: {},
getId: _encryptedStringValueGetId,
getLinks: _encryptedStringValueGetLinks,
attach: _encryptedStringValueAttach,
version: '3.0.5',
);
int _encryptedStringValueEstimateSize(
EncryptedStringValue object,
List<int> offsets,
Map<Type, List<int>> allOffsets,
) {
var bytesCount = offsets.last;
bytesCount += 3 + object.key.length * 3;
bytesCount += 3 + object.value.length * 3;
return bytesCount;
}
void _encryptedStringValueSerialize(
EncryptedStringValue object,
IsarWriter writer,
List<int> offsets,
Map<Type, List<int>> allOffsets,
) {
writer.writeString(offsets[0], object.key);
writer.writeString(offsets[1], object.value);
}
EncryptedStringValue _encryptedStringValueDeserialize(
Id id,
IsarReader reader,
List<int> offsets,
Map<Type, List<int>> allOffsets,
) {
final object = EncryptedStringValue();
object.id = id;
object.key = reader.readString(offsets[0]);
object.value = reader.readString(offsets[1]);
return object;
}
P _encryptedStringValueDeserializeProp<P>(
IsarReader reader,
int propertyId,
int offset,
Map<Type, List<int>> allOffsets,
) {
switch (propertyId) {
case 0:
return (reader.readString(offset)) as P;
case 1:
return (reader.readString(offset)) as P;
default:
throw IsarError('Unknown property with id $propertyId');
}
}
Id _encryptedStringValueGetId(EncryptedStringValue object) {
return object.id;
}
List<IsarLinkBase<dynamic>> _encryptedStringValueGetLinks(
EncryptedStringValue object) {
return [];
}
void _encryptedStringValueAttach(
IsarCollection<dynamic> col, Id id, EncryptedStringValue object) {
object.id = id;
}
extension EncryptedStringValueByIndex on IsarCollection<EncryptedStringValue> {
Future<EncryptedStringValue?> getByKey(String key) {
return getByIndex(r'key', [key]);
}
EncryptedStringValue? getByKeySync(String key) {
return getByIndexSync(r'key', [key]);
}
Future<bool> deleteByKey(String key) {
return deleteByIndex(r'key', [key]);
}
bool deleteByKeySync(String key) {
return deleteByIndexSync(r'key', [key]);
}
Future<List<EncryptedStringValue?>> getAllByKey(List<String> keyValues) {
final values = keyValues.map((e) => [e]).toList();
return getAllByIndex(r'key', values);
}
List<EncryptedStringValue?> getAllByKeySync(List<String> keyValues) {
final values = keyValues.map((e) => [e]).toList();
return getAllByIndexSync(r'key', values);
}
Future<int> deleteAllByKey(List<String> keyValues) {
final values = keyValues.map((e) => [e]).toList();
return deleteAllByIndex(r'key', values);
}
int deleteAllByKeySync(List<String> keyValues) {
final values = keyValues.map((e) => [e]).toList();
return deleteAllByIndexSync(r'key', values);
}
Future<Id> putByKey(EncryptedStringValue object) {
return putByIndex(r'key', object);
}
Id putByKeySync(EncryptedStringValue object, {bool saveLinks = true}) {
return putByIndexSync(r'key', object, saveLinks: saveLinks);
}
Future<List<Id>> putAllByKey(List<EncryptedStringValue> objects) {
return putAllByIndex(r'key', objects);
}
List<Id> putAllByKeySync(List<EncryptedStringValue> objects,
{bool saveLinks = true}) {
return putAllByIndexSync(r'key', objects, saveLinks: saveLinks);
}
}
extension EncryptedStringValueQueryWhereSort
on QueryBuilder<EncryptedStringValue, EncryptedStringValue, QWhere> {
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhere>
anyId() {
return QueryBuilder.apply(this, (query) {
return query.addWhereClause(const IdWhereClause.any());
});
}
}
extension EncryptedStringValueQueryWhere
on QueryBuilder<EncryptedStringValue, EncryptedStringValue, QWhereClause> {
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
idEqualTo(Id id) {
return QueryBuilder.apply(this, (query) {
return query.addWhereClause(IdWhereClause.between(
lower: id,
upper: id,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
idNotEqualTo(Id id) {
return QueryBuilder.apply(this, (query) {
if (query.whereSort == Sort.asc) {
return query
.addWhereClause(
IdWhereClause.lessThan(upper: id, includeUpper: false),
)
.addWhereClause(
IdWhereClause.greaterThan(lower: id, includeLower: false),
);
} else {
return query
.addWhereClause(
IdWhereClause.greaterThan(lower: id, includeLower: false),
)
.addWhereClause(
IdWhereClause.lessThan(upper: id, includeUpper: false),
);
}
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
idGreaterThan(Id id, {bool include = false}) {
return QueryBuilder.apply(this, (query) {
return query.addWhereClause(
IdWhereClause.greaterThan(lower: id, includeLower: include),
);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
idLessThan(Id id, {bool include = false}) {
return QueryBuilder.apply(this, (query) {
return query.addWhereClause(
IdWhereClause.lessThan(upper: id, includeUpper: include),
);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
idBetween(
Id lowerId,
Id upperId, {
bool includeLower = true,
bool includeUpper = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addWhereClause(IdWhereClause.between(
lower: lowerId,
includeLower: includeLower,
upper: upperId,
includeUpper: includeUpper,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
keyEqualTo(String key) {
return QueryBuilder.apply(this, (query) {
return query.addWhereClause(IndexWhereClause.equalTo(
indexName: r'key',
value: [key],
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterWhereClause>
keyNotEqualTo(String key) {
return QueryBuilder.apply(this, (query) {
if (query.whereSort == Sort.asc) {
return query
.addWhereClause(IndexWhereClause.between(
indexName: r'key',
lower: [],
upper: [key],
includeUpper: false,
))
.addWhereClause(IndexWhereClause.between(
indexName: r'key',
lower: [key],
includeLower: false,
upper: [],
));
} else {
return query
.addWhereClause(IndexWhereClause.between(
indexName: r'key',
lower: [key],
includeLower: false,
upper: [],
))
.addWhereClause(IndexWhereClause.between(
indexName: r'key',
lower: [],
upper: [key],
includeUpper: false,
));
}
});
}
}
extension EncryptedStringValueQueryFilter on QueryBuilder<EncryptedStringValue,
EncryptedStringValue, QFilterCondition> {
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> idEqualTo(Id value) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.equalTo(
property: r'id',
value: value,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> idGreaterThan(
Id value, {
bool include = false,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.greaterThan(
include: include,
property: r'id',
value: value,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> idLessThan(
Id value, {
bool include = false,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.lessThan(
include: include,
property: r'id',
value: value,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> idBetween(
Id lower,
Id upper, {
bool includeLower = true,
bool includeUpper = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.between(
property: r'id',
lower: lower,
includeLower: includeLower,
upper: upper,
includeUpper: includeUpper,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyEqualTo(
String value, {
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.equalTo(
property: r'key',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyGreaterThan(
String value, {
bool include = false,
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.greaterThan(
include: include,
property: r'key',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyLessThan(
String value, {
bool include = false,
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.lessThan(
include: include,
property: r'key',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyBetween(
String lower,
String upper, {
bool includeLower = true,
bool includeUpper = true,
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.between(
property: r'key',
lower: lower,
includeLower: includeLower,
upper: upper,
includeUpper: includeUpper,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyStartsWith(
String value, {
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.startsWith(
property: r'key',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyEndsWith(
String value, {
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.endsWith(
property: r'key',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition>
keyContains(String value, {bool caseSensitive = true}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.contains(
property: r'key',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition>
keyMatches(String pattern, {bool caseSensitive = true}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.matches(
property: r'key',
wildcard: pattern,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyIsEmpty() {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.equalTo(
property: r'key',
value: '',
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> keyIsNotEmpty() {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.greaterThan(
property: r'key',
value: '',
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueEqualTo(
String value, {
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.equalTo(
property: r'value',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueGreaterThan(
String value, {
bool include = false,
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.greaterThan(
include: include,
property: r'value',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueLessThan(
String value, {
bool include = false,
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.lessThan(
include: include,
property: r'value',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueBetween(
String lower,
String upper, {
bool includeLower = true,
bool includeUpper = true,
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.between(
property: r'value',
lower: lower,
includeLower: includeLower,
upper: upper,
includeUpper: includeUpper,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueStartsWith(
String value, {
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.startsWith(
property: r'value',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueEndsWith(
String value, {
bool caseSensitive = true,
}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.endsWith(
property: r'value',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition>
valueContains(String value, {bool caseSensitive = true}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.contains(
property: r'value',
value: value,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition>
valueMatches(String pattern, {bool caseSensitive = true}) {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.matches(
property: r'value',
wildcard: pattern,
caseSensitive: caseSensitive,
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueIsEmpty() {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.equalTo(
property: r'value',
value: '',
));
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue,
QAfterFilterCondition> valueIsNotEmpty() {
return QueryBuilder.apply(this, (query) {
return query.addFilterCondition(FilterCondition.greaterThan(
property: r'value',
value: '',
));
});
}
}
extension EncryptedStringValueQueryObject on QueryBuilder<EncryptedStringValue,
EncryptedStringValue, QFilterCondition> {}
extension EncryptedStringValueQueryLinks on QueryBuilder<EncryptedStringValue,
EncryptedStringValue, QFilterCondition> {}
extension EncryptedStringValueQuerySortBy
on QueryBuilder<EncryptedStringValue, EncryptedStringValue, QSortBy> {
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
sortByKey() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'key', Sort.asc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
sortByKeyDesc() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'key', Sort.desc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
sortByValue() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'value', Sort.asc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
sortByValueDesc() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'value', Sort.desc);
});
}
}
extension EncryptedStringValueQuerySortThenBy
on QueryBuilder<EncryptedStringValue, EncryptedStringValue, QSortThenBy> {
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
thenById() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'id', Sort.asc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
thenByIdDesc() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'id', Sort.desc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
thenByKey() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'key', Sort.asc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
thenByKeyDesc() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'key', Sort.desc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
thenByValue() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'value', Sort.asc);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QAfterSortBy>
thenByValueDesc() {
return QueryBuilder.apply(this, (query) {
return query.addSortBy(r'value', Sort.desc);
});
}
}
extension EncryptedStringValueQueryWhereDistinct
on QueryBuilder<EncryptedStringValue, EncryptedStringValue, QDistinct> {
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QDistinct>
distinctByKey({bool caseSensitive = true}) {
return QueryBuilder.apply(this, (query) {
return query.addDistinctBy(r'key', caseSensitive: caseSensitive);
});
}
QueryBuilder<EncryptedStringValue, EncryptedStringValue, QDistinct>
distinctByValue({bool caseSensitive = true}) {
return QueryBuilder.apply(this, (query) {
return query.addDistinctBy(r'value', caseSensitive: caseSensitive);
});
}
}
extension EncryptedStringValueQueryProperty on QueryBuilder<
EncryptedStringValue, EncryptedStringValue, QQueryProperty> {
QueryBuilder<EncryptedStringValue, int, QQueryOperations> idProperty() {
return QueryBuilder.apply(this, (query) {
return query.addPropertyName(r'id');
});
}
QueryBuilder<EncryptedStringValue, String, QQueryOperations> keyProperty() {
return QueryBuilder.apply(this, (query) {
return query.addPropertyName(r'key');
});
}
QueryBuilder<EncryptedStringValue, String, QQueryOperations> valueProperty() {
return QueryBuilder.apply(this, (query) {
return query.addPropertyName(r'value');
});
}
}