Package org.intermine.web.logic.results
Class ReportObjectFactory
- java.lang.Object
-
- org.intermine.util.ReferenceMap<K,V>
-
- org.intermine.util.SoftReferenceMap<K,V>
-
- org.intermine.util.CacheMap<InterMineObject,ReportObject>
-
- org.intermine.web.logic.results.ReportObjectFactory
-
- All Implemented Interfaces:
java.util.Map<InterMineObject,ReportObject>
public class ReportObjectFactory extends CacheMap<InterMineObject,ReportObject>
A factory for ReportObjects. If get() is called and the is no existing ReportObject for the argument InterMineObject, one is created, saved and returned.- Author:
- Radek Stepan (Kim Rutherford more like)
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.intermine.util.ReferenceMap
ReferenceMap.ReferenceWithKey<K>
-
-
Field Summary
-
Fields inherited from class org.intermine.util.ReferenceMap
name, NULL_VALUE, queue, subMap
-
-
Constructor Summary
Constructors Constructor Description ReportObjectFactory(InterMineAPI im, WebConfig webConfig, java.util.Properties webProperties)
Create a new ReportObjectCache for the given session.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
containsKey(java.lang.Object key)
Always returns true because get always returns an Object.ReportObject
get(java.lang.Object object)
Get a ReportObject for the given InterMineObject.ReportObject
put(InterMineObject key, ReportObject value)
Disable this method.-
Methods inherited from class org.intermine.util.SoftReferenceMap
newRef
-
Methods inherited from class org.intermine.util.ReferenceMap
clear, containsValue, entrySet, equals, hashCode, isEmpty, keySet, putAll, remove, size, toString, values
-
-
-
-
Constructor Detail
-
ReportObjectFactory
public ReportObjectFactory(InterMineAPI im, WebConfig webConfig, java.util.Properties webProperties)
Create a new ReportObjectCache for the given session.- Parameters:
im
- the InterMine APIwebConfig
- global web configurationwebProperties
- web properties
-
-
Method Detail
-
containsKey
public boolean containsKey(java.lang.Object key)
Always returns true because get always returns an Object.- Specified by:
containsKey
in interfacejava.util.Map<InterMineObject,ReportObject>
- Overrides:
containsKey
in classReferenceMap<InterMineObject,ReportObject>
-
get
public ReportObject get(java.lang.Object object)
Get a ReportObject for the given InterMineObject. If there is no existing ReportObject for the argument InterMineObject, one is created, saved and returned.- Specified by:
get
in interfacejava.util.Map<InterMineObject,ReportObject>
- Overrides:
get
in classReferenceMap<InterMineObject,ReportObject>
- Parameters:
object
- an InterMineObject to make a ReportObject for- Returns:
- a ReportObject
-
put
public ReportObject put(InterMineObject key, ReportObject value)
Disable this method.- Specified by:
put
in interfacejava.util.Map<InterMineObject,ReportObject>
- Overrides:
put
in classReferenceMap<InterMineObject,ReportObject>
- Parameters:
key
- Do not usevalue
- Do not use- Returns:
- never
-
-