You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this example we read from input.txt, convert it to base64 using the Base64EncoderStream and write the output to output.txt. Notice input is not directly disposed inside a using() statement but it will be disposed when base64Encoder is disposed.
The Base64DecoderStream works in exactly the same way except it expects the input to be properly formatted base64. By default it will ignore any whitespace in the input stream but you can override that to be more strict. If the input is not valid base64 an Exception will be thrown when you attempt to read.