Search Results for

    Show / Hide Table of Contents

    Class DicomPresentationContextCollection

    Collection of presentation contexts, with unique ID:s.

    Inheritance
    Object
    DicomPresentationContextCollection
    Implements
    ICollection<DicomPresentationContext>
    IEnumerable<DicomPresentationContext>
    IEnumerable
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Dicom.Network
    Assembly: cs.temp.dll.dll
    Syntax
    public class DicomPresentationContextCollection : ICollection<DicomPresentationContext>, IEnumerable<DicomPresentationContext>, IEnumerable

    Constructors

    DicomPresentationContextCollection()

    Initializes a new instance of DicomPresentationContextCollection.

    Declaration
    public DicomPresentationContextCollection()

    Properties

    Count

    Gets the number of presentation contexts in collection.

    Declaration
    public int Count { get; }
    Property Value
    Type Description
    Int32

    IsReadOnly

    Gets whether collection is read-only. Is always

    false
    .

    Declaration
    public bool IsReadOnly { get; }
    Property Value
    Type Description
    Boolean

    Item[Byte]

    Gets the presentation context associated with id.

    Declaration
    public DicomPresentationContext this[byte id] { get; }
    Parameters
    Type Name Description
    Byte id

    Presentation context ID.

    Property Value
    Type Description
    DicomPresentationContext

    Presentation context associated with id

    Methods

    Add(DicomUID, DicomTransferSyntax[])

    Initialize and add new presentation context.

    Declaration
    public void Add(DicomUID abstractSyntax, params DicomTransferSyntax[] transferSyntaxes)
    Parameters
    Type Name Description
    DicomUID abstractSyntax

    Abstract syntax of the presentation context.

    DicomTransferSyntax[] transferSyntaxes

    Supported transfer syntaxes.

    Add(DicomUID, Nullable<Boolean>, Nullable<Boolean>, DicomTransferSyntax[])

    Initialize and add new presentation context.

    Declaration
    public void Add(DicomUID abstractSyntax, bool? userRole, bool? providerRole, params DicomTransferSyntax[] transferSyntaxes)
    Parameters
    Type Name Description
    DicomUID abstractSyntax

    Abstract syntax of the presentation context.

    Nullable<Boolean> userRole

    Supports SCU role?

    Nullable<Boolean> providerRole

    Supports SCP role?

    DicomTransferSyntax[] transferSyntaxes

    Supported transfer syntaxes.

    Add(DicomPresentationContext)

    Adds an item to the ICollection<T>.

    Declaration
    public void Add(DicomPresentationContext item)
    Parameters
    Type Name Description
    DicomPresentationContext item

    The object to add to the ICollection<T>.

    Exceptions
    Type Condition
    NotSupportedException

    The ICollection<T> is read-only.

    AddFromRequest(DicomRequest)

    Add presentation contexts obtained from DICOM request.

    Declaration
    public void AddFromRequest(DicomRequest request)
    Parameters
    Type Name Description
    DicomRequest request

    Request from which presentation context(s) should be obtained.

    Clear()

    Clear all presentation contexts in collection.

    Declaration
    public void Clear()

    Contains(DicomPresentationContext)

    Indicates if specified presentation context is contained in collection.

    Declaration
    public bool Contains(DicomPresentationContext item)
    Parameters
    Type Name Description
    DicomPresentationContext item

    Presentation context to search for.

    Returns
    Type Description
    Boolean
    true
    if item is contained in collection,
    false
    otherwise.

    GetEnumerator()

    Returns an enumerator that iterates through the collection.

    Declaration
    public IEnumerator<DicomPresentationContext> GetEnumerator()
    Returns
    Type Description
    IEnumerator<DicomPresentationContext>

    A IEnumerator<T> that can be used to iterate through the collection.

    Remove(DicomPresentationContext)

    Removes the first occurrence of a specific object from the ICollection<T>.

    Declaration
    public bool Remove(DicomPresentationContext item)
    Parameters
    Type Name Description
    DicomPresentationContext item

    The object to remove from the ICollection<T>.

    Returns
    Type Description
    Boolean

    true if item was successfully removed from the ICollection<T>; otherwise, false. This method also returns false if item is not found in the original ICollection<T>.

    Exceptions
    Type Condition
    NotSupportedException

    The ICollection<T> is read-only.

    Explicit Interface Implementations

    ICollection<DicomPresentationContext>.CopyTo(DicomPresentationContext[], Int32)

    Copies the elements of the ICollection<T> to an Array, starting at a particular Array index.

    Declaration
    void ICollection<DicomPresentationContext>.CopyTo(DicomPresentationContext[] array, int arrayIndex)
    Parameters
    Type Name Description
    DicomPresentationContext[] array

    The one-dimensional Array that is the destination of the elements copied from ICollection<T>. The Array must have zero-based indexing.

    Int32 arrayIndex

    The zero-based index in array at which copying begins.

    Exceptions
    Type Condition
    ArgumentNullException

    array is null.

    ArgumentOutOfRangeException

    arrayIndex is less than 0.

    ArgumentException

    The number of elements in the source ICollection<T> is greater than the available space from arrayIndex to the end of the destination array.

    Implements

    System.Collections.Generic.ICollection<T>
    System.Collections.Generic.IEnumerable<T>
    System.Collections.IEnumerable
    In This Article
    Back to top Copyright (c) 2012-2021 fo-dicom contributors