Avro C#
Loading...
Searching...
No Matches
Avro.Reflect.FuncFieldConverter< TAvro, TProperty > Class Template Reference

Field converter using a Func. More...

Inheritance diagram for Avro.Reflect.FuncFieldConverter< TAvro, TProperty >:
Avro.Reflect.TypedFieldConverter< TAvro, TProperty > Avro.Reflect.IAvroFieldConverter

Public Member Functions

 FuncFieldConverter (Func< TAvro, Schema, TProperty > from, Func< TProperty, Schema, TAvro > to)
 Initializes a new instance of the FuncFieldConverter<A, P> class.
override TProperty From (TAvro o, Schema s)
 Inherited conversion method - call the Func.
override TAvro To (TProperty o, Schema s)
 Inherited conversion method - call the Func.
Public Member Functions inherited from Avro.Reflect.TypedFieldConverter< TAvro, TProperty >
TProperty From (TAvro o, Schema s)
 Convert from Avro type to property type.
TAvro To (TProperty o, Schema s)
 Convert from property type to Avro type.
object FromAvroType (object o, Schema s)
 Implement untyped interface.
Type GetAvroType ()
 Implement untyped interface.
Type GetPropertyType ()
 Implement untyped interface.
object ToAvroType (object o, Schema s)
 Implement untyped interface.

Detailed Description

Field converter using a Func.

Template Parameters
TAvroAvro type
TPropertyProperty type

Member Function Documentation

◆ From()

override TProperty Avro.Reflect.FuncFieldConverter< TAvro, TProperty >.From ( TAvro o,
Schema s )
inline

Inherited conversion method - call the Func.

Parameters
o
s
Returns

◆ FuncFieldConverter()

Avro.Reflect.FuncFieldConverter< TAvro, TProperty >.FuncFieldConverter ( Func< TAvro, Schema, TProperty > from,
Func< TProperty, Schema, TAvro > to )
inline

Initializes a new instance of the FuncFieldConverter<A, P> class.

Parameters
fromDelegate to convert from C# type to Avro type
toDelegate to convert from Avro type to C# type

◆ To()

override TAvro Avro.Reflect.FuncFieldConverter< TAvro, TProperty >.To ( TProperty o,
Schema s )
inline

Inherited conversion method - call the Func.

Parameters
o
s
Returns

The documentation for this class was generated from the following file:
  • src/apache/main/Reflect/FuncFieldConverter.cs