Yet more instances of Lists changed over to native arrays

This commit is contained in:
Eric Banks 2012-06-12 15:56:09 -04:00
parent 613badc835
commit 277493dd83
1 changed files with 3 additions and 3 deletions

View File

@ -611,13 +611,13 @@ public class RecalDataManager {
* @param requestedCovariates The list of requested covariates. * @param requestedCovariates The list of requested covariates.
* @return a matrix with all the covariates calculated for every base in the read * @return a matrix with all the covariates calculated for every base in the read
*/ */
public static ReadCovariates computeCovariates(final GATKSAMRecord read, final List<Covariate> requestedCovariates) { public static ReadCovariates computeCovariates(final GATKSAMRecord read, final Covariate[] requestedCovariates) {
final int numRequestedCovariates = requestedCovariates.size(); final int numRequestedCovariates = requestedCovariates.length;
final int readLength = read.getReadLength(); final int readLength = read.getReadLength();
final ReadCovariates readCovariates = new ReadCovariates(readLength, numRequestedCovariates); final ReadCovariates readCovariates = new ReadCovariates(readLength, numRequestedCovariates);
// Loop through the list of requested covariates and compute the values of each covariate for all positions in this read // Loop through the list of requested covariates and compute the values of each covariate for all positions in this read
for (Covariate covariate : requestedCovariates) for (final Covariate covariate : requestedCovariates)
readCovariates.addCovariate(covariate.getValues(read)); readCovariates.addCovariate(covariate.getValues(read));
return readCovariates; return readCovariates;