Beispiel #1
0
    public Coord makeRangeSafe(CoRange _coRa)
    {
        Coord retCo      = Coord.Max(this, _coRa.start);
        Coord outerMinus = _coRa.outerLimit() - 1;

        return(Coord.Min(this, outerMinus));
    }
Beispiel #2
0
    public bool isInsideOfRange(CoRange coRange)
    {
        Coord outerLimit = coRange.outerLimit();

        return((Coord.greaterThanOrEqual(this, coRange.start)) && (Coord.greaterThan(outerLimit, this)));


        //		return this.isInsideOfRange (coRange.start, coRange.range);
    }
Beispiel #3
0
    public bool isInsideOfRangeInclusive(CoRange coRange)
    {
        Coord outerLimit = coRange.outerLimit();

        return((Coord.greaterThanOrEqual(this, coRange.start)) && (Coord.greaterThanOrEqual(outerLimit, this)));
    }
Beispiel #4
0
    public static bool Contains(CoRange container, CoRange contained)
    {
        bool startIsLess = Coord.greaterThanOrEqual(contained.start, container.start);

        return(Coord.greaterThan(container.outerLimit(), contained.outerLimit()));
    }