
org.intermine.util.CacheHoldingArrayList Maven / Gradle / Ivy
package org.intermine.util;
/*
* Copyright (C) 2002-2022 FlyMine
*
* This code may be freely distributed and modified under the
* terms of the GNU Lesser General Public Licence. This should
* be distributed with the code. See the LICENSE file for more
* information or http://www.gnu.org/copyleft/lesser.html.
*
*/
import java.util.ArrayList;
import java.util.Collection;
/**
* This is an extension of the the ArrayList class, designed to be used by systems that return
* Lists of data, with extra data that should not be flushed out of a cache until the List is
* garbage collected.
*
* This is used for example in the ObjectStoreItemPathFollowingImpl, when it generates a batch.
* The objectstore fetches additional useful objects, and stores them in the holder of a
* CacheHoldingArrayList as well as a cache. The holder them prevents the extra useful objects from
* being flushed out of the cache until the DataTranslator has finished with the batch.
*
* @author Matthew Wakeling
* @param The element type
*/
public class CacheHoldingArrayList extends ArrayList
{
private ArrayList
© 2015 - 2025 Weber Informatics LLC | Privacy Policy