Show / Hide Table of Contents

Class Bundle

Provides a set of factory methods to create bundles of objects which are stored in a memory-efficient manner.

Inheritance
System.Object
Bundle
Namespace: System.Memory
Assembly: Nuqleon.Memory.dll
Syntax
public static class Bundle : Object

Methods

Create(IEnumerable<Object>)

Creates a bundle with the specified items.

Declaration
public static IReadOnlyIndexed Create(IEnumerable<object> items)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<System.Object> items

Items to include in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Create(Object[])

Creates a bundle with the specified items.

Declaration
public static IReadOnlyIndexed Create(params object[] items)
Parameters
Type Name Description
System.Object[] items

Items to include in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Create<T1>(T1)

Creates a bundle with one item.

Declaration
public static IReadOnlyIndexed Create<T1>(T1 item1)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10)

Creates a bundle with ten items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11)

Creates a bundle with eleven items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10, T11 item11)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

T11 item11

The eleventh item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10
T11

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12)

Creates a bundle with twelve items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10, T11 item11, T12 item12)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

T11 item11

The eleventh item in the bundle.

T12 item12

The twelfth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10
T11
T12

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13)

Creates a bundle with thirteen items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10, T11 item11, T12 item12, T13 item13)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

T11 item11

The eleventh item in the bundle.

T12 item12

The twelfth item in the bundle.

T13 item13

The thirteenth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10
T11
T12
T13

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14)

Creates a bundle with fourteen items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10, T11 item11, T12 item12, T13 item13, T14 item14)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

T11 item11

The eleventh item in the bundle.

T12 item12

The twelfth item in the bundle.

T13 item13

The thirteenth item in the bundle.

T14 item14

The fourteenth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10
T11
T12
T13
T14

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15)

Creates a bundle with fifteen items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10, T11 item11, T12 item12, T13 item13, T14 item14, T15 item15)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

T11 item11

The eleventh item in the bundle.

T12 item12

The twelfth item in the bundle.

T13 item13

The thirteenth item in the bundle.

T14 item14

The fourteenth item in the bundle.

T15 item15

The fifteenth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10
T11
T12
T13
T14
T15

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, TRest>(T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, TRest)

Creates a bundle with fifteen items and a bundle with remainder items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12, T13, T14, T15, TRest>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9, T10 item10, T11 item11, T12 item12, T13 item13, T14 item14, T15 item15, TRest rest)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

T10 item10

The tenth item in the bundle.

T11 item11

The eleventh item in the bundle.

T12 item12

The twelfth item in the bundle.

T13 item13

The thirteenth item in the bundle.

T14 item14

The fourteenth item in the bundle.

T15 item15

The fifteenth item in the bundle.

TRest rest

The remainder items in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
T10
T11
T12
T13
T14
T15
TRest

Create<T1, T2>(T1, T2)

Creates a bundle with two items.

Declaration
public static IReadOnlyIndexed Create<T1, T2>(T1 item1, T2 item2)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2

Create<T1, T2, T3>(T1, T2, T3)

Creates a bundle with three items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3>(T1 item1, T2 item2, T3 item3)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3

Create<T1, T2, T3, T4>(T1, T2, T3, T4)

Creates a bundle with four items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4>(T1 item1, T2 item2, T3 item3, T4 item4)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4

Create<T1, T2, T3, T4, T5>(T1, T2, T3, T4, T5)

Creates a bundle with five items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5

Create<T1, T2, T3, T4, T5, T6>(T1, T2, T3, T4, T5, T6)

Creates a bundle with six items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6

Create<T1, T2, T3, T4, T5, T6, T7>(T1, T2, T3, T4, T5, T6, T7)

Creates a bundle with seven items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7

Create<T1, T2, T3, T4, T5, T6, T7, T8>(T1, T2, T3, T4, T5, T6, T7, T8)

Creates a bundle with eight items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8

Create<T1, T2, T3, T4, T5, T6, T7, T8, T9>(T1, T2, T3, T4, T5, T6, T7, T8, T9)

Creates a bundle with nine items.

Declaration
public static IReadOnlyIndexed Create<T1, T2, T3, T4, T5, T6, T7, T8, T9>(T1 item1, T2 item2, T3 item3, T4 item4, T5 item5, T6 item6, T7 item7, T8 item8, T9 item9)
Parameters
Type Name Description
T1 item1

The first item in the bundle.

T2 item2

The second item in the bundle.

T3 item3

The third item in the bundle.

T4 item4

The fourth item in the bundle.

T5 item5

The fifth item in the bundle.

T6 item6

The sixth item in the bundle.

T7 item7

The seventh item in the bundle.

T8 item8

The eighth item in the bundle.

T9 item9

The ninth item in the bundle.

Returns
Type Description
IReadOnlyIndexed

Bundle value with the specified items.

Type Parameters
Name Description
T1
T2
T3
T4
T5
T6
T7
T8
T9
In This Article
Back to top Generated by DocFX