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
infoSerializationInfoThe SerializationInfo that holds the serialized object data about the exception being thrown.
contextStreamingContextThe 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
messagestringThe error message that explains the reason for the exception.
marketIdintThe id of the market associated with name generation that caused the exception
marketSpecifiersIReadOnlyDictionary<string, string>The specifiers of the market associated with name generation that caused the exception
outcomeIdstringThe id of the outcome whose name generation caused the exception, or a null reference if the name generation was invoked on market
nameDescriptorstringThe name descriptor used when generating the name, or a null reference if name descriptor could not be found
cultureCultureInfoThe CultureInfo instance specifying the language associated with the name generation
innerExceptionExceptionThe 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
MarketId
Gets the id of the market associated with name generation that caused the exception
public int MarketId { get; }
Property Value
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
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
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
infoSerializationInfoThe SerializationInfo that holds the serialized object data about the exception being thrown.
contextStreamingContextThe StreamingContext that contains contextual information about the source or destination.
ToString()
Returns a string that represents this instance.
public override string ToString()