ZipItem<I1, I2> class Null safety

Class for a pair belonging to a zip with some functionality including: swapping, ==, to & From type constructors, [] operations.

Constructors

ZipItem(I1 item1, I2 item2)
ZipItem.fromList(List list)
Creates ZipItem from list of exactly 2
factory
ZipItem.fromMap(Map<String, dynamic> map)
factory

Properties

hashCode int
The hash code for this object.
read-onlyoverride
item1 ↔ I1
read / write
item2 ↔ I2
read / write
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited

Methods

copyWith({I1? item1, I2? item2}) ZipItem<I1, I2>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
swap() ZipItem<I2, I1>
Returns shallow copy with item1 & item2 swapped
toList() List
toMap() Map<String, dynamic>
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
override
operator [](int index) → dynamic
[0] retrieves first item [1] retrieves 2nd, negative numbers retrieve [0] if even or [1] if odd
operator []=(int index, dynamic newVal) → void