Skip to content

Instantly share code, notes, and snippets.

@enebo
Created December 16, 2010 21:42
Show Gist options
  • Save enebo/744072 to your computer and use it in GitHub Desktop.
Save enebo/744072 to your computer and use it in GitHub Desktop.
public class SafeArray {
/**
* Contains a compressed sequence of n-dimensions of array values.
*/
private Variant[] values;
// Each array dimensions first index in the pangea values array
private int valueIndexFor[];
// Which index represents the start of each elements array (arrays can
// have non-zero index value.
private int startIndices[];
// How long is a particular dimension
private int lengths[];
// Type stored in variant array. We need this value since Array could
// be empty and we would not be able to ask an element for type name
private int variantType;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment