class KeyedStateCheckpointOutputStream extends NonClosingCheckpointOutputStream<KeyGroupsStateHandle> {

	@Override
	KeyGroupsStateHandle closeAndGetHandle() throws IOException {
		StreamStateHandle streamStateHandle = super.closeAndGetHandleAfterLeasesReleased();
		return streamStateHandle != null ? new KeyGroupsStateHandle(keyGroupRangeOffsets, streamStateHandle) : null;
	}

	public  KeyedStateCheckpointOutputStream(
			CheckpointStreamFactory.CheckpointStateOutputStream delegate, KeyGroupRange keyGroupRange);

}