component1

inline operator fun <F, S> Pair<F, S>.component1(): F(source)
inline operator fun <F, S> Pair<F, S>.component1(): F(source)

Returns the first component of the pair.

This method allows to use destructuring declarations when working with pairs, for example:

val (first, second) = myPair

@RequiresApi(value = 21)
inline operator fun Size.component1(): Int(source)

Returns "width", the first component of this Size.

This method allows to use destructuring declarations when working with sizes, for example:

val (w, h) = mySize

@RequiresApi(value = 21)
inline operator fun SizeF.component1(): Float(source)

Returns "width", the first component of this SizeF.

This method allows to use destructuring declarations when working with sizes, for example:

val (w, h) = mySize

inline operator fun SizeFCompat.component1(): Float(source)

Returns "width", the first component of this SizeFCompat.

This method allows to use destructuring declarations when working with sizes, for example:

val (w, h) = mySize