T - public interface Domain<T>
Represents a finite domain of abstract values where each value is given a unique index starting from zero. The key characteristics of any domain are its size, and the ability to get any given element efficiently.
As an example, consider the domain of integer arrays for integers
between 0 and 1. Values in this domain might be
ordered like so:
0 = [] 1 = [0] 2 = [1] 3 = [0,0] 4 = [1,0] 5 = [0,1] 6 = [1,1] 7 = [0,0,0] ...Observe there are an infinite number of values here and, to create a finite domain, we would need to place a cap on the number of elements.
| Modifier and Type | Method and Description |
|---|---|
T |
get(long index)
Get a given value from the domain determined by its index.
|
long |
size()
Determine how many objects this generator can produce
|
Domain<T> |
slice(long start,
long end)
Return a subdomain of this domain which includes all elements between the
start (inclusive) and end index (exlusive).
|
long size()
T get(long index)
kind - Copyright © 2019. All rights reserved.