See Also

EnhancedStream Class  | EnhancedStream Members  | Overload List

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

Language

Visual Basic

C#

C++

C++/CLI

Show All

destination
The destination stream.
resetPosition
Controls whether or not the positions of the source and destination streams are reset during the "copy" process.
See Also Languages PowerTCP SSL Sockets for .NET

WriteTo(Stream,Boolean) Method

Dart.PowerTCP.SslSockets Namespace > EnhancedStream Class > WriteTo Method : WriteTo(Stream,Boolean) Method

Writes all of the data contained in this Stream to a destination Stream.

[Visual Basic]
Overloads Public Sub WriteTo( _    ByVal destination As Stream, _    ByVal resetPosition As Boolean _ )
[C#]
public void WriteTo(    Stream destination,    bool resetPosition );
[C++]
public: void WriteTo(    Stream* destination,    bool resetPosition )
[C++/CLI]
public: void WriteTo(    Stream^ destination,    bool resetPosition )

Parameters

destination
The destination stream.
resetPosition
Controls whether or not the positions of the source and destination streams are reset during the "copy" process.

Exceptions

ExceptionDescription
NullReferenceExceptiondestination is null.
IOExceptionStream is not readable or writeable.

Remarks

If resetPositions is true, this method essentially "copies" one stream to another by setting the destination Stream position to zero, writing all of the data in the source Stream to the destination, resetting the source Stream back to its original position, and resetting the destination to a position of zero.

If resetPositions is false, it copies from the current location of the source Stream to the current location of destination, and positions are not set.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

See Also

EnhancedStream Class  | EnhancedStream Members  | Overload List


Send comments on this topic.

Documentation version 1.1.2.0.

© 2008 Dart Communications.  All rights reserved.