Summary
Represents a list of Discriminated unions. Using this list you can add items without having to specify the union type.
- Namespace
- FunctionalSharp
.DiscriminatedUnions - Interfaces
-
- IList
< Discriminated Union <Type1, Type2, Type3, Type4> > - ICollection
< Discriminated Union <Type1, Type2, Type3, Type4> > - IList
- ICollection
- IReadOnlyList
< Discriminated Union <Type1, Type2, Type3, Type4> > - IReadOnlyCollection
< Discriminated Union <Type1, Type2, Type3, Type4> > - IEnumerable
< Discriminated Union <Type1, Type2, Type3, Type4> > - IEnumerable
- IList
- Base Types
-
- object
- List
< Discriminated Union <Type1, Type2, Type3, Type4> >
graph TD
Base0["List<DiscriminatedUnion<Type1, Type2, Type3, Type4>>"]-->Type
Base1["object"]-->Base0
Interface0["IList<DiscriminatedUnion<Type1, Type2, Type3, Type4>>"]-.->Type
Interface1["ICollection<DiscriminatedUnion<Type1, Type2, Type3, Type4>>"]-.->Type
Interface2["IList"]-.->Type
Interface3["ICollection"]-.->Type
Interface4["IReadOnlyList<DiscriminatedUnion<Type1, Type2, Type3, Type4>>"]-.->Type
Interface5["IReadOnlyCollection<DiscriminatedUnion<Type1, Type2, Type3, Type4>>"]-.->Type
Interface6["IEnumerable<DiscriminatedUnion<Type1, Type2, Type3, Type4>>"]-.->Type
Interface7["IEnumerable"]-.->Type
Type["DiscriminatedUnionList<Type1, Type2, Type3, Type4>"]
class Type type-node
Syntax
[Serializable]
public class DiscriminatedUnionList<Type1, Type2, Type3, Type4> :
List<DiscriminatedUnion<Type1, Type2, Type3, Type4>>,
IList<DiscriminatedUnion<Type1, Type2, Type3, Type4>>,
ICollection<DiscriminatedUnion<Type1, Type2, Type3, Type4>>, IList, ICollection,
IReadOnlyList<DiscriminatedUnion<Type1, Type2, Type3, Type4>>,
IReadOnlyCollection<DiscriminatedUnion<Type1, Type2, Type3, Type4>>,
IEnumerable<DiscriminatedUnion<Type1, Type2, Type3, Type4>>, IEnumerable
Attributes
Type | Description |
---|---|
Serializable |
Type Parameters
Name | Description |
---|---|
Type1 | Type1 |
Type2 | Type2 |
Type3 | Type3 |
Type4 | Type4 |
Methods
Name | Value | Summary |
---|---|---|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
AddRange |
void |
Adds the object to the end of the DiscriminatedUnionList
|
AddRange |
void |
Adds the object to the end of the DiscriminatedUnionList
|
AddRange |
void |
Adds the object to the end of the DiscriminatedUnionList
|
AddRange |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Merge |
Discriminated |
Merges a type into the existing discriminated union list.
|
Extension Methods
Name | Value | Summary |
---|---|---|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
Add |
void |
Adds the object to the end of the DiscriminatedUnionList
|
AddRange |
void |
Adds a Enumerable of items to the list.
|
AddRange |
void |
Adds a Enumerable of items to the list.
|
AddRange |
void |
Adds a Enumerable of items to the list.
|
AddRange |
void |
Adds a Enumerable of items to the list.
|
Match |
PatternMatchContext |
Starts a pattern match. Subsequent calls to With() need to be used to specify conditions
|
Match |
Pattern |
Starts a pattern match for a single value. Subsequent calls to With() need to be used to specify conditions
|
Match |
IEnumerable |
Matches the specific types and uses the given functions to tranform into s ingle returntype.
|
Match |
void |
Matches the specific types and executes the given action for them.
|
MatchDiscriminated |
Discriminated |
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges the item intos the existing discriminatedunions resulting in a new enumerable of discriminated unions with the type of the items as a new option.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
Merge |
IEnumerable |
Merges to given collections into a discriminated union collection.
|
MergeItem |
IEnumerable |
Merges the item into the existing discriminatedunions resulting in a new enumerable of discriminated unions with the type of the item as a new option.
|
SafeSingle |
DiscriminatedUnion |
provides a mechanism to use Single on a collection that returns a discriminated union instead of an exception.
From LinqExtensions
|
ToOption |
IOption |
Turns the type T into an option type.
From OptionExtensions
|