Struct axgeom::Range [] [src]

#[must_use]
pub struct Range<T: Copy> { pub start: T, pub end: T, }

A 1d range. Internally represented as start and end. (not start and length) This means that subdivision does not result in any floating point calculations. There is no protection against "degenerate" Ranges where start>end.

Fields

Methods

impl<T: Copy + Debug + Ord> Range<T>
[src]

[src]

If the pos is to the left of the range, return less. If the pos is to the right of the range, return greater. If the pos intersects with the range, return equal.

[src]

[src]

Returns true if the point is inside of the range or on top of.

[src]

Returns true if self contains the specified range.

[src]

Creates a range that represents the intersection range.

[src]

Returns true if two ranges intersect.

impl Range<f32>
[src]

[src]

[src]

Grow in both ends by the specified value.

[src]

impl<T: Copy + Debug> Range<T>
[src]

[src]

[src]

Trait Implementations

impl<T: Copy + Copy> Copy for Range<T>
[src]

impl<T: Clone + Copy> Clone for Range<T>
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl<T: Debug + Copy> Debug for Range<T>
[src]

[src]

Formats the value using the given formatter.

impl<T: PartialEq + Copy + Debug> PartialEq for Range<T>
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

1.0.0
[src]

This method tests for !=.