Interface ReferenceCounting
-
- All Known Implementing Classes:
ReferenceCountingReadOnlyIndexReaderFactory.ReferenceCountingReadOnlyIndexReader
public interface ReferenceCountingReference counting and caching for read only index access. When this object is invalid for reuse and all referees have gone the implementation should release all resources held (release the caches, close the index readers etc)- Author:
- andyh
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longgetCreationTime()java.lang.StringgetId()Get the id for this reader.intgetReferenceCount()Get the number of referencesjava.util.Deque<java.lang.Throwable>getReferences()booleanisInvalidForReuse()Determine if valid for reusevoidsetInvalidForReuse()Mark is invalid for reuse.
-
-
-
Method Detail
-
getCreationTime
long getCreationTime()
-
getReferences
java.util.Deque<java.lang.Throwable> getReferences()
-
getReferenceCount
int getReferenceCount()
Get the number of references- Returns:
- int
-
setInvalidForReuse
void setInvalidForReuse() throws java.io.IOExceptionMark is invalid for reuse.- Throws:
java.io.IOException
-
isInvalidForReuse
boolean isInvalidForReuse()
Determine if valid for reuse- Returns:
- boolean
-
getId
java.lang.String getId()
Get the id for this reader.- Returns:
- String
-
-