Module gridly::location

source ·
Expand description

Location type used to index into grids, as well as associated types and traits.

Structs

  • A column component of a Location. See Component for details.
  • A location on a grid. A location is the primary indexing type for a Grid, and represents a single cell on that grid. It is comprised of a Row and a Column. Increasing row count downward and increasing columns count rightward.
  • Rules for ordering a location. This struct wraps a LocationLike and supplies an Ord and PartialOrd implementation. The Major type parameter indicates which ordering is used; for instance, Ordering<Row> provides row-major ordering, where Locations are sorted first by row, then by column.
  • A row component of a Location. See Component for details.

Traits

  • A component of a Location, which may be either a Row or a Column. It is effectively an index into a given row or column of a grid; for instance, a Row can index a row in a grid.
  • This trait covers structs that act like a Location, such as tuples. See the Location documentation for more details.

Type Aliases