public class DoubleArray extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_CAPACITY |
| Constructor and Description |
|---|
DoubleArray()
Creates a sorted int array with a default initial capacity
|
DoubleArray(int capacity)
Creates an IntArray with a given initial capacity
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(double x)
add value to the array
|
void |
add(int pos,
double x) |
double[] |
array() |
boolean |
equals(Object obj) |
double |
get(int pos)
get element at position
|
int |
hashCode() |
boolean |
isEmpty() |
void |
set(int pos,
double x) |
int |
size() |
double[] |
toArray() |
String |
toString() |
static DoubleArray |
wrap(double[] doubles) |
public DoubleArray()
public DoubleArray(int capacity)
capacity - public void add(double x)
x - public void add(int pos,
double x)
public double get(int pos)
pos - public boolean isEmpty()
public double[] toArray()
public int size()
public void set(int pos,
double x)
public static DoubleArray wrap(double[] doubles)
public double[] array()
Copyright © 2018 Space Applications Services. All rights reserved.