@@ -176,6 +176,7 @@ public QueryLayer ComposeForGetByIdForNoSql<TId>(TId id, ResourceType primaryRes
176
176
} ;
177
177
}
178
178
179
+ /// <inheritdoc />
179
180
public ( QueryLayer QueryLayer , IncludeExpression Include ) ComposeForUpdateForNoSql < TId > ( TId id , ResourceType primaryResourceType )
180
181
where TId : notnull
181
182
{
@@ -250,7 +251,9 @@ public override bool DefaultVisit(QueryExpression expression, object? argument)
250
251
/// <inheritdoc />
251
252
public override bool VisitComparison ( ComparisonExpression expression , object ? argument )
252
253
{
253
- return expression . Left . Accept ( this , argument ) && expression . Right . Accept ( this , argument ) ;
254
+ _isSimpleFilterExpression &= expression . Left . Accept ( this , argument ) && expression . Right . Accept ( this , argument ) ;
255
+
256
+ return _isSimpleFilterExpression ;
254
257
}
255
258
256
259
/// <inheritdoc />
@@ -279,49 +282,66 @@ private static bool HasOwnsManyAttribute(ResourceFieldAttribute field)
279
282
/// <inheritdoc />
280
283
public override bool VisitLogical ( LogicalExpression expression , object ? argument )
281
284
{
282
- return expression . Terms . All ( term => term . Accept ( this , argument ) ) ;
285
+ _isSimpleFilterExpression &= expression . Terms . All ( term => term . Accept ( this , argument ) ) ;
286
+
287
+ return _isSimpleFilterExpression ;
283
288
}
284
289
285
290
/// <inheritdoc />
286
291
public override bool VisitNot ( NotExpression expression , object ? argument )
287
292
{
288
- return expression . Child . Accept ( this , argument ) ;
293
+ _isSimpleFilterExpression &= expression . Child . Accept ( this , argument ) ;
294
+
295
+ return _isSimpleFilterExpression ;
289
296
}
290
297
291
298
/// <inheritdoc />
292
299
public override bool VisitHas ( HasExpression expression , object ? argument )
293
300
{
294
- return expression . TargetCollection . Accept ( this , argument ) && ( expression . Filter is null || expression . Filter . Accept ( this , argument ) ) ;
301
+ _isSimpleFilterExpression &= expression . TargetCollection . Accept ( this , argument ) &&
302
+ ( expression . Filter is null || expression . Filter . Accept ( this , argument ) ) ;
303
+
304
+ return _isSimpleFilterExpression ;
295
305
}
296
306
297
307
/// <inheritdoc />
298
308
public override bool VisitSortElement ( SortElementExpression expression , object ? argument )
299
309
{
300
- return expression . TargetAttribute is null || expression . TargetAttribute . Accept ( this , argument ) ;
310
+ _isSimpleFilterExpression &= expression . TargetAttribute is null || expression . TargetAttribute . Accept ( this , argument ) ;
311
+
312
+ return _isSimpleFilterExpression ;
301
313
}
302
314
303
315
/// <inheritdoc />
304
316
public override bool VisitSort ( SortExpression expression , object ? argument )
305
317
{
306
- return expression . Elements . All ( element => element . Accept ( this , argument ) ) ;
318
+ _isSimpleFilterExpression &= expression . Elements . All ( element => element . Accept ( this , argument ) ) ;
319
+
320
+ return _isSimpleFilterExpression ;
307
321
}
308
322
309
323
/// <inheritdoc />
310
324
public override bool VisitCount ( CountExpression expression , object ? argument )
311
325
{
312
- return expression . TargetCollection . Accept ( this , argument ) ;
326
+ _isSimpleFilterExpression &= expression . TargetCollection . Accept ( this , argument ) ;
327
+
328
+ return _isSimpleFilterExpression ;
313
329
}
314
330
315
331
/// <inheritdoc />
316
332
public override bool VisitMatchText ( MatchTextExpression expression , object ? argument )
317
333
{
318
- return expression . TargetAttribute . Accept ( this , argument ) ;
334
+ _isSimpleFilterExpression &= expression . TargetAttribute . Accept ( this , argument ) ;
335
+
336
+ return _isSimpleFilterExpression ;
319
337
}
320
338
321
339
/// <inheritdoc />
322
340
public override bool VisitAny ( AnyExpression expression , object ? argument )
323
341
{
324
- return expression . TargetAttribute . Accept ( this , argument ) ;
342
+ _isSimpleFilterExpression &= expression . TargetAttribute . Accept ( this , argument ) ;
343
+
344
+ return _isSimpleFilterExpression ;
325
345
}
326
346
}
327
347
}
0 commit comments