Implement UprCloseStream API