XFileManager.FromStream Method

Language:

Note: This documentation is preliminary and is subject to change.

Creates an XFile object from a data stream.

Definition

Visual Basic .NET Public Function FromStream( _
    ByVal data As Stream _
) As XFile
C# public XFile FromStream(
    Stream data
);
Managed C++ public: XFile* FromStream(
    Stream *data
);
JScript .NET public function FromStream(
    data : Stream
) : XFile;

Parameters

data System.IO.Stream. A Stream Leave Site that contains the .x file data.

Return Value

Microsoft.DirectX.Direct3D.XFile . A newly created XFile object.

Remarks

After using this method, use one of the XFile methods to retrieve a data object.

Exception GraphicsException.ErrorCode Cause
GraphicsException XFileErrorCodes.BadValue A variable is outside its expected range; typically returned when an object is invalid.
XFileErrorCodes.ParseError Data stream could not be parsed.
ArgumentOutOfRangeException Leave Site N/A Length must be greater than zero.
NotSupportedException Leave Site N/A The stream must support reading.


© 2004 Microsoft Corporation. All rights reserved. Terms of use.

Feedback? Please provide us with your comments on this topic.