02.05.2014 Views

CoreandServices.book - Ocean - Schlumberger

CoreandServices.book - Ocean - Schlumberger

CoreandServices.book - Ocean - Schlumberger

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Basics<br />

The definition of the IndexRange4 class is:<br />

public class IndexRange4 : IndexRangeKdBase<br />

{<br />

public IndexRange4 (Index4 begin, Index4 end);<br />

public IndexRange4 (IndexRange1 r0, IndexRange1 r1,<br />

IndexRange1 r2, IndexRange1 r3);<br />

public Index4 Begin { get; }<br />

public override int Dim { get; }<br />

public Index4 End { get; }<br />

public Index4 Size { get; }<br />

public override int BeginVal (int dim);<br />

public override object Clone ();<br />

public bool Contains (Index4 val);<br />

public bool Contains (Index4 pos, Index4 begin, Index4 end);<br />

public override int EndVal (int dim);<br />

public override int GetHashCode ();<br />

public static IndexRange4 Intersection (IndexRange4 lhs,<br />

IndexRange4 rhs);<br />

protected override void SetBeginVal (int val, int dim);<br />

protected override void SetEndVal (int val, int dim);<br />

}<br />

public static explicit operator IndexRange4 (IndexRange2 arg);<br />

public static explicit operator IndexRange4 (IndexRange3 arg);<br />

The IndexRange1 class represents a single dimensioned range. The IndexRange1<br />

class will use integers where the other classes use Index2, Index3, or Index4<br />

parameters. The constructor for an IndexRange1 simply requires beginning and ending<br />

values.<br />

int begin = 5;<br />

int end = 15;<br />

IndexRange1 ir = new IndexRange1 (begin, end);<br />

Likewise the properties Begin, End, and Size return integer values instead of Index<br />

objects.<br />

4-108 <strong>Ocean</strong> Application Development Framework 2008.1<br />

<strong>Schlumberger</strong> Private

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!