1 package org.djunits.value; 2 3 /** 4 * Possible ways to store vectors and matrices, e.g. DENSE or SPARSE. 5 * <p> 6 * Copyright (c) 2013-2018 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. <br> 7 * BSD-style license. See <a href="http://opentrafficsim.org/docs/license.html">OpenTrafficSim License</a>. 8 * </p> 9 * $LastChangedDate: 2015-07-24 02:58:59 +0200 (Fri, 24 Jul 2015) $, @version $Revision: 1147 $, by $Author: averbraeck $, 10 * initial version Oct 9, 2015 <br> 11 * @author <a href="http://www.tbm.tudelft.nl/averbraeck">Alexander Verbraeck</a> 12 * @author <a href="http://www.tudelft.nl/pknoppers">Peter Knoppers</a> 13 */ 14 public enum StorageType 15 { 16 /** 17 * Dense storage. Use Dense to store small quantities of values, or values where zero is not common, or larger access times 18 * are unacceptable, or memory availability is high. 19 */ 20 DENSE, 21 22 /** 23 * Sparse storage. Use Sparse to store large quantities of values when most are zero and larger access times are acceptable 24 * and memory availability is low. Changing a zero value to a non-zero value is CPU-time-expensive 25 */ 26 SPARSE; 27 }