public void streamClosed()

in src/main/java/com/amazonaws/kinesisvideo/internal/producer/jni/NativeKinesisVideoProducerStream.java [469:501]


    public void streamClosed(final long uploadHandle) throws ProducerException
    {
        mLog.debug("Stream %s is closed", mStreamInfo.getName());

        if (uploadHandle == ReadResult.INVALID_UPLOAD_HANDLE_VALUE) {
            for (final Map.Entry<Long, NativeDataInputStream> stream : mInputStreamMap.entrySet()) {
                try {
                    stream.getValue().close();
                    if (mStreamCallbacks != null) {
                        mStreamCallbacks.streamClosed(stream.getKey());
                    }
                } catch (final IOException e) {
                    mLog.error("stream close failed with exception ", e);
                }
            }

            // Release the stopped latch
            mStoppedLatch.countDown();
        } else {
            try {
                mInputStreamMap.get(uploadHandle).close();
            } catch (final IOException e) {
                mLog.error("stream close failed with exception ", e);
            }

            // Release the stopped latch
            mStoppedLatch.countDown();

            if (mStreamCallbacks != null) {
                mStreamCallbacks.streamClosed(uploadHandle);
            }
        }
    }