java.lang.Object
java.io.InputStream
com.aoapps.sql.wrapper.InputStreamWrapper
com.aoapps.sql.tracker.InputStreamTracker
- All Implemented Interfaces:
NoClose,OnCloseHandler,Wrapper,Closeable,AutoCloseable,Wrapper
Tracks an
InputStream for unclosed or unfreed objects.- Author:
- AO Industries, Inc.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final LevelThe logging level that enables allocation stack trace logging. -
Constructor Summary
ConstructorsConstructorDescriptionInputStreamTracker(ConnectionTrackerImpl connectionTracker, InputStream wrapped) Creates a newInputStreamtracker. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddOnClose(Runnable onCloseHandler) Will call the handler once on close/free.voidclose()Calls onClose handlers thensuper.close().Methods inherited from class com.aoapps.sql.wrapper.InputStreamWrapper
available, getConnectionWrapper, getWrapped, isNoClose, mark, markSupported, read, read, read, readAllBytes, readNBytes, readNBytes, reset, skip, toString, transferToMethods inherited from class java.io.InputStream
nullInputStreamMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.aoapps.sql.wrapper.Wrapper
isWrapperFor, unwrap
-
Field Details
-
ALLOCATION_STACKTRACE_LOG_LEVEL
The logging level that enables allocation stack trace logging.
-
-
Constructor Details
-
InputStreamTracker
Creates a newInputStreamtracker.
-
-
Method Details
-
getAllocationStacktrace
-
getAllocationLogger
-
addOnClose
Description copied from interface:OnCloseHandlerWill call the handler once on close/free.- Specified by:
addOnClosein interfaceOnCloseHandler
-
close
Calls onClose handlers thensuper.close().- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Specified by:
closein interfaceNoClose- Overrides:
closein classInputStreamWrapper- Throws:
IOException- See Also:
-
