Package org.epics.util.array
Class ListInteger
- java.lang.Object
-
- org.epics.util.array.ListInteger
-
- All Implemented Interfaces:
CollectionInteger,CollectionNumber,ListNumber
- Direct Known Subclasses:
ArrayInteger,BufferInteger
public abstract class ListInteger extends Object implements ListNumber, CollectionInteger
An ordered collection ofints.- Author:
- Gabriele Carcassi
-
-
Constructor Summary
Constructors Constructor Description ListInteger()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)bytegetByte(int index)Returns the element at the specified position in this list casted to a byte.doublegetDouble(int index)Returns the element at the specified position in this list casted to a double.floatgetFloat(int index)Returns the element at the specified position in this list casted to a float.longgetLong(int index)Returns the element at the specified position in this list casted to a long.shortgetShort(int index)Returns the element at the specified position in this list casted to a short.inthashCode()IteratorIntegeriterator()Returns an iterator over the elements of the collection.voidsetAll(int index, ListNumber list)Changes the elements starting at the specified position, taking them based on the internal representation.voidsetByte(int index, byte value)Changes the element at the specified position, casting to the internal representation.voidsetDouble(int index, double value)Changes the element at the specified position, casting to the internal representation.voidsetFloat(int index, float value)Changes the element at the specified position, casting to the internal representation.voidsetInt(int index, int value)Changes the element at the specified position, casting to the internal representation.voidsetLong(int index, long value)Changes the element at the specified position, casting to the internal representation.voidsetShort(int index, short value)Changes the element at the specified position, casting to the internal representation.ListIntegersubList(int fromIndex, int toIndex)Returns a view of the portion of this list between the specified fromIndex, inclusive, and toIndex, exclusive.StringtoString()-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.epics.util.array.CollectionNumber
size, toArray
-
Methods inherited from interface org.epics.util.array.ListNumber
getInt
-
-
-
-
Method Detail
-
iterator
public IteratorInteger iterator()
Description copied from interface:CollectionNumberReturns an iterator over the elements of the collection.- Specified by:
iteratorin interfaceCollectionInteger- Specified by:
iteratorin interfaceCollectionNumber- Returns:
- a new iterator
-
getDouble
public double getDouble(int index)
Description copied from interface:ListNumberReturns the element at the specified position in this list casted to a double.- Specified by:
getDoublein interfaceListNumber- Parameters:
index- position of the element to return- Returns:
- the element at the specified position in this list
-
getFloat
public float getFloat(int index)
Description copied from interface:ListNumberReturns the element at the specified position in this list casted to a float.- Specified by:
getFloatin interfaceListNumber- Parameters:
index- position of the element to return- Returns:
- the element at the specified position in this list
-
getLong
public long getLong(int index)
Description copied from interface:ListNumberReturns the element at the specified position in this list casted to a long.- Specified by:
getLongin interfaceListNumber- Parameters:
index- position of the element to return- Returns:
- the element at the specified position in this list
-
getShort
public short getShort(int index)
Description copied from interface:ListNumberReturns the element at the specified position in this list casted to a short.- Specified by:
getShortin interfaceListNumber- Parameters:
index- position of the element to return- Returns:
- the element at the specified position in this list
-
getByte
public byte getByte(int index)
Description copied from interface:ListNumberReturns the element at the specified position in this list casted to a byte.- Specified by:
getBytein interfaceListNumber- Parameters:
index- position of the element to return- Returns:
- the element at the specified position in this list
-
setDouble
public void setDouble(int index, double value)Description copied from interface:ListNumberChanges the element at the specified position, casting to the internal representation.- Specified by:
setDoublein interfaceListNumber- Parameters:
index- position of the element to changevalue- the new value
-
setFloat
public void setFloat(int index, float value)Description copied from interface:ListNumberChanges the element at the specified position, casting to the internal representation.- Specified by:
setFloatin interfaceListNumber- Parameters:
index- position of the element to changevalue- the new value
-
setLong
public void setLong(int index, long value)Description copied from interface:ListNumberChanges the element at the specified position, casting to the internal representation.- Specified by:
setLongin interfaceListNumber- Parameters:
index- position of the element to changevalue- the new value
-
setInt
public void setInt(int index, int value)Description copied from interface:ListNumberChanges the element at the specified position, casting to the internal representation.- Specified by:
setIntin interfaceListNumber- Parameters:
index- position of the element to changevalue- the new value
-
setShort
public void setShort(int index, short value)Description copied from interface:ListNumberChanges the element at the specified position, casting to the internal representation.- Specified by:
setShortin interfaceListNumber- Parameters:
index- position of the element to changevalue- the new value
-
setByte
public void setByte(int index, byte value)Description copied from interface:ListNumberChanges the element at the specified position, casting to the internal representation.- Specified by:
setBytein interfaceListNumber- Parameters:
index- position of the element to changevalue- the new value
-
setAll
public void setAll(int index, ListNumber list)Description copied from interface:ListNumberChanges the elements starting at the specified position, taking them based on the internal representation.- Specified by:
setAllin interfaceListNumber- Parameters:
index- position of the first element to changelist- the new values
-
subList
public ListInteger subList(int fromIndex, int toIndex)
Description copied from interface:ListNumberReturns a view of the portion of this list between the specified fromIndex, inclusive, and toIndex, exclusive.- Specified by:
subListin interfaceListNumber- Parameters:
fromIndex- low endpoint (inclusive) of the subListtoIndex- high endpoint (exclusive) of the subList- Returns:
- a view of the specified range within this list
-
-