Table of Contents

Class NameGenerationException

Namespace
Sportradar.OddsFeed.SDK.Common.Exceptions
Assembly
Sportradar.OddsFeed.SDK.dll

An exception when the name for a market or outcome could not be generated

[Serializable]
public class NameGenerationException : FeedSdkException, ISerializable
Inheritance
NameGenerationException
Implements
Inherited Members

Constructors

NameGenerationException()

Initializes a new instance of the NameGenerationException class.

public NameGenerationException()

NameGenerationException(SerializationInfo, StreamingContext)

Initializes a new instance of the NameGenerationException class.

public NameGenerationException(SerializationInfo info, StreamingContext context)

Parameters

info SerializationInfo

The SerializationInfo that holds the serialized object data about the exception being thrown.

context StreamingContext

The StreamingContext that contains contextual information about the source or destination.

NameGenerationException(string, int, IReadOnlyDictionary<string, string>, string, string, CultureInfo, Exception)

Initializes a new instance of the NameGenerationException class.

public NameGenerationException(string message, int marketId, IReadOnlyDictionary<string, string> marketSpecifiers, string outcomeId, string nameDescriptor, CultureInfo culture, Exception innerException)

Parameters

message string

The error message that explains the reason for the exception.

marketId int

The id of the market associated with name generation that caused the exception

marketSpecifiers IReadOnlyDictionary<string, string>

The specifiers of the market associated with name generation that caused the exception

outcomeId string

The id of the outcome whose name generation caused the exception, or a null reference if the name generation was invoked on market

nameDescriptor string

The name descriptor used when generating the name, or a null reference if name descriptor could not be found

culture CultureInfo

The CultureInfo instance specifying the language associated with the name generation

innerException Exception

The exception that is the cause of the current exception, or a null reference if no inner exception is specified.

Properties

Culture

Gets the CultureInfo instance specifying the language associated with the name generation

public CultureInfo Culture { get; }

Property Value

CultureInfo

MarketId

Gets the id of the market associated with name generation that caused the exception

public int MarketId { get; }

Property Value

int

MarketSpecifiers

Gets the specifiers of the market associated with name generation that caused the exception

public IReadOnlyDictionary<string, string> MarketSpecifiers { get; }

Property Value

IReadOnlyDictionary<string, string>

The market specifiers.

NameDescriptor

Gets the name descriptor used when generating the name, or a null reference if name descriptor could not be found

public string NameDescriptor { get; }

Property Value

string

OutcomeId

Gets the id of the outcome whose name generation caused the exception, or a null reference if the name generation was invoked on market

public string OutcomeId { get; }

Property Value

string

Methods

GetObjectData(SerializationInfo, StreamingContext)

When overridden in a derived class, sets the SerializationInfo with information about the exception.

public override void GetObjectData(SerializationInfo info, StreamingContext context)

Parameters

info SerializationInfo

The SerializationInfo that holds the serialized object data about the exception being thrown.

context StreamingContext

The StreamingContext that contains contextual information about the source or destination.

ToString()

Returns a string that represents this instance.

public override string ToString()

Returns

string

A string that represents this instance.

See Also