Class DictInlineInitializationException
- Namespace
- Gym.Collections
- Assembly
- Gym.dll
Thrown by the legacy Dict's inline-pairs constructor and AddInline(params object[]) when the arguments are not key-value pairs: an odd count, a null key, or a key that is not exactly a string. The pairs before the bad one are already in the dictionary when it is thrown.
[Serializable]
[Obsolete("Thrown only by the legacy Dict's inline pairs; Gym.Envs.Info needs none (new Info { [\"key\"] = value } is checked when it compiles). Removed in 2.0 with Gym.Legacy.")]
public class DictInlineInitializationException : Exception, ISerializable
- Inheritance
-
DictInlineInitializationException
- Implements
- Inherited Members
- Extension Methods
Remarks
Obsolete with Dict (DR-56) and removed in 2.0. Info needs no such error:
its collection initializer (new Info { ["key"] = value }) is checked when it compiles.
Constructors
DictInlineInitializationException()
An error without a message of its own (.NET's default text).
public DictInlineInitializationException()
DictInlineInitializationException(string)
An error saying which rule the inline pairs broke.
public DictInlineInitializationException(string message)
Parameters
messagestringThe rule broken, as AddInline(params object[]) words it.
DictInlineInitializationException(string, Exception)
An error with a message and its cause.
public DictInlineInitializationException(string message, Exception inner)