-
Notifications
You must be signed in to change notification settings - Fork 35
T_CodeJam_OneOf_8
Andrew Koryavchenko edited this page Jun 17, 2018
·
2 revisions
Tagged union for 8 types.
System.Object
CodeJam.OneOf(T1, T2, T3, T4, T5, T6, T7, T8)
Namespace: CodeJam
Assembly: CodeJam (in CodeJam.dll) Version: 2.1.0.0
C#
public abstract class OneOf<T1, T2, T3, T4, T5, T6, T7, T8> : IOneOf<T1, T2, T3, T4, T5, T6, T7, T8>,
IEquatable<OneOf<T1, T2, T3, T4, T5, T6, T7, T8>>
VB
Public MustInherit Class OneOf(Of T1, T2, T3, T4, T5, T6, T7, T8)
Implements IOneOf(Of T1, T2, T3, T4, T5, T6, T7, T8),
IEquatable(Of OneOf(Of T1, T2, T3, T4, T5, T6, T7, T8))
F#
[<AbstractClassAttribute>]
type OneOf<'T1, 'T2, 'T3, 'T4, 'T5, 'T6, 'T7, 'T8> =
class
interface IOneOf<'T1, 'T2, 'T3, 'T4, 'T5, 'T6, 'T7, 'T8>
interface IEquatable<OneOf<'T1, 'T2, 'T3, 'T4, 'T5, 'T6, 'T7, 'T8>>
end
- T1
- Type of case 1
- T2
- Type of case 2
- T3
- Type of case 3
- T4
- Type of case 4
- T5
- Type of case 5
- T6
- Type of case 6
- T7
- Type of case 7
- T8
- Type of case 8
Name | Description | |
---|---|---|
OneOf(T1, T2, T3, T4, T5, T6, T7, T8) | Initializes a new instance of the OneOf(T1, T2, T3, T4, T5, T6, T7, T8) class |
Name | Description | |
---|---|---|
IsCase1 |
Returns true if class contains value of type T1. |
|
IsCase2 |
Returns true if class contains value of type T2. |
|
IsCase3 |
Returns true if class contains value of type T3. |
|
IsCase4 |
Returns true if class contains value of type T4. |
|
IsCase5 |
Returns true if class contains value of type T5. |
|
IsCase6 |
Returns true if class contains value of type T6. |
|
IsCase7 |
Returns true if class contains value of type T7. |
|
IsCase8 |
Returns true if class contains value of type T8. |
Name | Description | |
---|---|---|
Create(T1) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T1. | |
Create(T2) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T2. | |
Create(T3) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T3. | |
Create(T4) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T4. | |
Create(T5) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T5. | |
Create(T6) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T6. | |
Create(T7) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T7. | |
Create(T8) | Creates instance of OneOf(T1, T2, T3, T4, T5, T6, T7, T8) for value of type T8. | |
Do | Calls action for actual type argument. | |
Equals(Object) | Determines whether the specified object is equal to the current object. (Overrides Object.Equals(Object).) | |
Equals(OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Indicates whether the current object is equal to another object of the same type. | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetHashCode | Serves as the default hash function. (Overrides Object.GetHashCode().) | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
GetValue(TResult) | Calls func for actual type argument and returns calculated value. | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
Equality | Equality operator. | |
Implicit(T1 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T2 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T3 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T4 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T5 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T6 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T7 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Implicit(T8 to OneOf(T1, T2, T3, T4, T5, T6, T7, T8)) | Implicit cast operator. | |
Inequality | Unequality operator. |