DicomObjects.NET.8.48 Documentation
DicomObjects Namespace / DicomDataSet Class / Write Method / Write(Stream,String,Object,DicomDataSet,WriteBehaviours) Method

The Stream to which to write.

Specifies the full UID of the transfer syntax with which the file is to be saved when Part 10 format is used. If omitted, the little-endian explicit VR transfer syntax is used.

The quality factor to be used.

The customized MetaHeader (only Group 2 Elements)

Specific options to use when writing the data







In This Topic
    Write(Stream,String,Object,DicomDataSet,WriteBehaviours) Method
    In This Topic
    Writes dataset to a stream with specified transfer syntax, quality factor, meta header and behaviour overrides
    Syntax
    'Declaration
     
    
    Public Overloads Sub Write( _
       ByVal Stream As System.IO.Stream, _
       ByVal TransferSyntax As System.String, _
       ByVal Quality As System.Object, _
       ByVal MetaHeader As DicomDataSet, _
       ByVal Behaviour As WriteBehaviours _
    ) 
    'Usage
     
    
    Dim instance As DicomDataSet
    Dim Stream As System.IO.Stream
    Dim TransferSyntax As System.String
    Dim Quality As System.Object
    Dim MetaHeader As DicomDataSet
    Dim Behaviour As WriteBehaviours
     
    instance.Write(Stream, TransferSyntax, Quality, MetaHeader, Behaviour)
    public void Write( 
       System.IO.Stream Stream,
       System.string TransferSyntax,
       System.object Quality,
       DicomDataSet MetaHeader,
       WriteBehaviours Behaviour
    )
    public procedure Write( 
        Stream: System.IO.Stream;
        TransferSyntax: System.String;
        Quality: System.TObject;
        MetaHeader: DicomDataSet;
        Behaviour: WriteBehaviours
    ); 
    public function Write( 
       Stream : System.IO.Stream,
       TransferSyntax : System.String,
       Quality : System.Object,
       MetaHeader : DicomDataSet,
       Behaviour : WriteBehaviours
    );
    public: void Write( 
       System.IO.Stream* Stream,
       System.string* TransferSyntax,
       System.Object* Quality,
       DicomDataSet* MetaHeader,
       WriteBehaviours* Behaviour
    ) 
    public:
    void Write( 
       System.IO.Stream^ Stream,
       System.String^ TransferSyntax,
       System.Object^ Quality,
       DicomDataSet^ MetaHeader,
       WriteBehaviours^ Behaviour
    ) 

    Parameters

    Stream

    The Stream to which to write.

    TransferSyntax

    Specifies the full UID of the transfer syntax with which the file is to be saved when Part 10 format is used. If omitted, the little-endian explicit VR transfer syntax is used.

    Quality

    The quality factor to be used.

    MetaHeader

    The customized MetaHeader (only Group 2 Elements)

    Behaviour

    Specific options to use when writing the data

    Remarks

    The file may subsequently be read by the Read method or by other DICOM software.

    Quality is specific to the compression method being used, and is ignored for non-compressed or lossless JPEG transfer syntaxes. For Lossy JPEG, it is an integer in the range 1-100, the higher the number, the better the quality (and the larger the file), and for JPEG 2000 lossy, it is a compression ratio. Other compression methods may use this for other purposes in the future.

    The provided MetaHeader should only contain group 2 elements.

    Requirements

    Target Platforms: .NET CLR 4.8 or higher

    See Also