Class DiscriminatorBuilder
Represents a discriminator builder for defining the properties of an entity type.
Inheritance
DiscriminatorBuilder
Assembly: Innovt.Cloud.AWS.Dynamo.dll
Syntax
public class DiscriminatorBuilder
Constructors
|
Edit this page
View Source
DiscriminatorBuilder(string, EntityTypeBuilder)
Represents a discriminator builder for defining the properties of an entity type.
Declaration
public DiscriminatorBuilder(string name, EntityTypeBuilder builder)
Parameters
Properties
|
Edit this page
View Source
Builder
Declaration
public EntityTypeBuilder Builder { get; }
Property Value
|
Edit this page
View Source
Name
The column name that will be used to store the discriminator.
Declaration
public string Name { get; set; }
Property Value
Methods
|
Edit this page
View Source
GetTypeForDiscriminator(int)
Get the type for the discriminator.
Declaration
public Type GetTypeForDiscriminator(int value)
Parameters
Type |
Name |
Description |
int |
value |
|
Returns
|
Edit this page
View Source
GetTypeForDiscriminator(string)
Get the type for the discriminator.
Declaration
public Type GetTypeForDiscriminator(string value)
Parameters
Type |
Name |
Description |
string |
value |
|
Returns
|
Edit this page
View Source
GetValue(int)
Get the instance of a object with a discriminator value
Declaration
public object GetValue(int value)
Parameters
Type |
Name |
Description |
int |
value |
|
Returns
|
Edit this page
View Source
GetValue(string)
Get the instance of a object with a discriminator value
Declaration
public object GetValue(string value)
Parameters
Type |
Name |
Description |
string |
value |
|
Returns
|
Edit this page
View Source
GetValue<T>(int)
Get the value type for the discriminator value
Declaration
public T GetValue<T>(int value)
Parameters
Type |
Name |
Description |
int |
value |
|
Returns
Type Parameters
|
Edit this page
View Source
GetValue<T>(string)
Get the value type for the discriminator value
Declaration
public T GetValue<T>(string value)
Parameters
Type |
Name |
Description |
string |
value |
|
Returns
Type Parameters
|
Edit this page
View Source
HasValue<T>()
Simple case of a class that can inherit from another class.
Declaration
public DiscriminatorBuilder HasValue<T>() where T : new()
Returns
Type Parameters
|
Edit this page
View Source
HasValue<T>(int)
Use this method when you have a type T with a parameterless constructor and will be created when matched the whenValue parameter
Declaration
public DiscriminatorBuilder HasValue<T>(int whenValue) where T : new()
Parameters
Type |
Name |
Description |
int |
whenValue |
|
Returns
Type Parameters
|
Edit this page
View Source
HasValue<T>(string)
Use this method when you have a type T with a parameterless constructor and will be created when matched the whenValue parameter
Declaration
public DiscriminatorBuilder HasValue<T>(string whenValue) where T : new()
Parameters
Type |
Name |
Description |
string |
whenValue |
|
Returns
Type Parameters
|
Edit this page
View Source
HasValue<T>(T)
Use this method when you need to define a value for a specific type.
Declaration
public DiscriminatorBuilder HasValue<T>(T value)
Parameters
Type |
Name |
Description |
T |
value |
|
Returns
Type Parameters
|
Edit this page
View Source
HasValue<T>(T, int)
Use this method when you want to define a value for a specific type and a specific value.
Declaration
public DiscriminatorBuilder HasValue<T>(T value, int whenValue)
Parameters
Type |
Name |
Description |
T |
value |
|
int |
whenValue |
|
Returns
Type Parameters
|
Edit this page
View Source
HasValue<T>(T, string)
Use this method when you want to define a value for a specific type and a specific value.
Declaration
public DiscriminatorBuilder HasValue<T>(T value, string whenValue)
Parameters
Type |
Name |
Description |
T |
value |
|
string |
whenValue |
|
Returns
Type Parameters
Extension Methods