Fauna v10 .NET/C# Driver
0.2.0-beta
Loading...
Searching...
No Matches
Fauna
Serialization
Serializers
StreamSerializer.cs
Go to the documentation of this file.
1
using
Fauna.Mapping
;
2
using
Fauna.Types
;
3
using
Stream
=
Fauna
.
Types
.
Stream
;
4
5
namespace
Fauna.Serialization
;
6
7
8
internal
class
StreamSerializer : BaseSerializer<Stream>
9
{
10
public
override
Stream
Deserialize(
MappingContext
context, ref Utf8FaunaReader reader) =>
11
reader.CurrentTokenType
switch
12
{
13
TokenType.Stream => reader.GetStream(),
14
_ =>
throw
UnexpectedToken
(reader.CurrentTokenType)
15
};
16
17
public
override
void
Serialize(
MappingContext
context, Utf8FaunaWriter writer,
object
? o)
18
{
19
throw
new
NotImplementedException();
20
}
21
}
Fauna.Mapping.MappingContext
A class representing the mapping context to be used during serialization and deserialization.
Definition
MappingContext.cs:9
Fauna.Serialization.BaseSerializer< Stream >::UnexpectedToken
static SerializationException UnexpectedToken(TokenType token)
Fauna.Types.Stream
Represents a Fauna stream token.
Definition
Stream.cs:7
Fauna.Mapping
Definition
Attributes.cs:1
Fauna.Serialization
Definition
ISerializer.cs:3
Fauna.Types
Definition
BaseDocument.cs:3
Fauna
Definition
Client.cs:8
Generated by
1.12.0