0

I have a CipherInputStream created from an InputStream and Cipher passed to its constructor.

I want to know the size of that stream, is there any way of doing the same? will available() give me the result what I expect?

I know answers like read the stream to determine same and such inefficient ones easily available on internet, but I want an efficient way of doing the same.

I already asked one question here for the same issue but there I did not mention exact class of the stream. also I tried searching on the internet but could not find any proper answer.

Community
  • 1
  • 1
dev2d
  • 4,245
  • 3
  • 31
  • 54

1 Answers1

0

No, available cannot tell you the full size of the stream because it depends on the underlying stream.

Axel
  • 13,939
  • 5
  • 50
  • 79