Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ public class Sample
db.Sample.FindByBarAndFoo((int Bar, int Foo))
```

Default of `FindBy***` return type is single(if not found, returns `null`). It means key is unique by default. If mark `[NonUnique]` in same AttributeList, return type is `RangeView<T>`(if not found, return empty).
By default, `FindBy***` returns a single element and throws `KeyNotFoundException` if the key is not found. Keys are unique by default. To return `null` for a missing unique key instead, set `IsReturnNullIfKeyNotFound = true` in `[MasterMemoryGeneratorOptions]`. If marked with `[NonUnique]` in the same AttributeList, the return type is `RangeView<T>` (empty if not found).

```csharp
[MemoryTable("sample"), MessagePackObject(true)]
Expand Down