Fellow Oak DICOM
Search Results for

    Show / Hide Table of Contents

    Class DicomPresentationContextCollection

    Collection of presentation contexts, with unique ID:s.

    Inheritance
    System.Object
    DicomPresentationContextCollection
    Implements
    System.Collections.Generic.ICollection<DicomPresentationContext>
    System.Collections.Generic.IEnumerable<DicomPresentationContext>
    System.Collections.IEnumerable
    Inherited Members
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.ToString()
    Namespace: FellowOakDicom.Network
    Assembly: fo-dicom.core.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
    System.Int32

    IsReadOnly

    Gets whether collection is read-only. Is always

    false
    .

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

    Item[Byte]

    Gets the presentation context associated with id.

    Declaration
    public DicomPresentationContext this[byte id] { get; }
    Parameters
    Type Name Description
    System.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.

    System.Nullable<System.Boolean> userRole

    Supports SCU role?

    System.Nullable<System.Boolean> providerRole

    Supports SCP role?

    DicomTransferSyntax[] transferSyntaxes

    Supported transfer syntaxes.

    Add(DicomPresentationContext)

    Adds an item to the System.Collections.Generic.ICollection<T>.

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

    The object to add to the System.Collections.Generic.ICollection<T>.

    Exceptions
    Type Condition
    System.NotSupportedException

    The System.Collections.Generic.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
    System.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
    System.Collections.Generic.IEnumerator<DicomPresentationContext>

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

    Remove(DicomPresentationContext)

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

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

    The object to remove from the System.Collections.Generic.ICollection<T>.

    Returns
    Type Description
    System.Boolean

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

    Exceptions
    Type Condition
    System.NotSupportedException

    The System.Collections.Generic.ICollection<T> is read-only.

    Explicit Interface Implementations

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

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

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

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

    System.Int32 arrayIndex

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

    Exceptions
    Type Condition
    System.ArgumentNullException

    array is null.

    System.ArgumentOutOfRangeException

    arrayIndex is less than 0.

    System.ArgumentException

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

    IEnumerable.GetEnumerator()

    Returns an enumerator that iterates through a collection.

    Declaration
    IEnumerator IEnumerable.GetEnumerator()
    Returns
    Type Description
    System.Collections.IEnumerator

    An System.Collections.IEnumerator object that can be used to iterate through the collection.

    Implements

    System.Collections.Generic.ICollection<T>
    System.Collections.Generic.IEnumerable<T>
    System.Collections.IEnumerable

    Extension Methods

    EnumerableExtensions.Each<T>(IEnumerable<T>, Action<T>)
    LinqExtensions.Diff<S, T>(IEnumerable<S>, Func<S, S, T>)
    LinqExtensions.FilterByType<T>(IEnumerable<Object>)
    LinqExtensions.IsOneOf<T>(T, T[])
    In This Article
    Back to top Copyright (c) 2012-2025 fo-dicom contributors