public class JIPipeDataItemStore extends Object implements AutoCloseable, Closeable, Store<JIPipeData>
Constructor and Description |
---|
JIPipeDataItemStore(JIPipeData data)
Create virtual data from data
|
Modifier and Type | Method and Description |
---|---|
void |
addUser(Object obj)
Marks the provided object as user of this data
|
boolean |
canClose()
Returns true if the data has no users and thus can be closed
|
void |
close() |
JIPipeDataItemStore |
duplicate(JIPipeProgressInfo progressInfo)
Fully duplicates the virtual data
|
JIPipeData |
get()
Gets the stored data or null if the data is not present
|
protected JIPipeData |
getData_(JIPipeProgressInfo progressInfo)
Gets the currently stored data
|
<T extends JIPipeData> |
getData(Class<T> klass,
JIPipeProgressInfo progressInfo)
Gets the currently stored data.
|
JIPipeData |
getData(JIPipeProgressInfo progressInfo)
Gets the currently stored data
|
Class<? extends JIPipeData> |
getDataClass() |
String |
getStringRepresentation() |
JIPipeThumbnailData |
getThumbnail()
Gets the currently stored thumbnail
|
boolean |
isClosed()
Returns true if this object is closed and thus should not be used anymore
|
boolean |
isPresent()
Returns true if the stored data is present
|
void |
removeUser(Object obj)
Un-marks the provided objects as user of this data
|
void |
setThumbnail(JIPipeThumbnailData thumbnail)
Sets the thumbnail
|
public JIPipeDataItemStore(JIPipeData data)
data
- datapublic JIPipeDataItemStore duplicate(JIPipeProgressInfo progressInfo)
progressInfo
- the progress infopublic boolean isClosed()
public <T extends JIPipeData> T getData(Class<T> klass, JIPipeProgressInfo progressInfo)
T
- the output typeklass
- the output typeprogressInfo
- the progress infopublic JIPipeThumbnailData getThumbnail()
public void setThumbnail(JIPipeThumbnailData thumbnail)
thumbnail
- the thumbnail or nullprotected JIPipeData getData_(JIPipeProgressInfo progressInfo)
progressInfo
- the progress infopublic JIPipeData getData(JIPipeProgressInfo progressInfo)
progressInfo
- the progress infopublic String getStringRepresentation()
public Class<? extends JIPipeData> getDataClass()
public void addUser(Object obj)
obj
- the objectpublic void removeUser(Object obj)
obj
- the objectpublic boolean canClose()
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
public JIPipeData get()
Store
get
in interface Store<JIPipeData>
public boolean isPresent()
Store
isPresent
in interface Store<JIPipeData>
Copyright © 2020–2025 Leibniz Institute for Natural Product Research and Infection Biology - Hans Knöll Institute (HKI). All rights reserved.