Indexed

com.phasmidsoftware.tableparser.core.table.Indexed
See theIndexed companion class
object Indexed

Companion object for the Indexed case class, providing utility methods to create and work with indexed collections.

Attributes

Companion
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
Indexed.type

Members list

Type members

Inherited and Abstract types

type MirroredElemLabels <: Tuple

The names of the product elements.

The names of the product elements.

Attributes

Inherited from:
Mirror
type MirroredLabel <: String

The name of the type.

The name of the type.

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def apply[T](tuple: (T, Int)): Indexed[T]

Creates an Indexed instance from a tuple containing a value of type T and an integer index.

Creates an Indexed instance from a tuple containing a value of type T and an integer index.

Type parameters

T

The type of the first element in the tuple.

Value parameters

tuple

A tuple where the first element is of type T and the second element is an Int representing the index.

Attributes

Returns

An Indexed instance containing the provided index and value, with the order of elements reversed.

def index[T](rows: Iterable[T]): Seq[Indexed[T]]

Creates a sequence of Indexed instances by associating each element of the input collection with a zero-based index.

Creates a sequence of Indexed instances by associating each element of the input collection with a zero-based index.

Type parameters

T

the type of elements in the input collection

Value parameters

rows

the input collection of elements to be indexed

Attributes

Returns

a sequence of Indexed instances, where each element is paired with its index