org.apache.lucene.util
Class IntsRef

java.lang.Object
  extended by org.apache.lucene.util.IntsRef
All Implemented Interfaces:
Comparable<IntsRef>

public final class IntsRef
extends Object
implements Comparable<IntsRef>

Represents int[], as a slice (offset + length) into an existing int[].

NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.

Field Summary
 int[] ints
           
 int length
           
 int offset
           
 
Constructor Summary
IntsRef()
           
IntsRef(int capacity)
           
IntsRef(int[] ints, int offset, int length)
           
IntsRef(IntsRef other)
           
 
Method Summary
 Object clone()
           
 int compareTo(IntsRef other)
          Signed int order comparison
 void copy(IntsRef other)
           
 boolean equals(Object other)
           
 void grow(int newLength)
           
 int hashCode()
           
 boolean intsEquals(IntsRef other)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ints

public int[] ints

offset

public int offset

length

public int length
Constructor Detail

IntsRef

public IntsRef()

IntsRef

public IntsRef(int capacity)

IntsRef

public IntsRef(int[] ints,
               int offset,
               int length)

IntsRef

public IntsRef(IntsRef other)
Method Detail

clone

public Object clone()
Overrides:
clone in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object other)
Overrides:
equals in class Object

intsEquals

public boolean intsEquals(IntsRef other)

compareTo

public int compareTo(IntsRef other)
Signed int order comparison

Specified by:
compareTo in interface Comparable<IntsRef>

copy

public void copy(IntsRef other)

grow

public void grow(int newLength)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2000-2011 Apache Software Foundation. All Rights Reserved.