다음을 통해 공유


ITextBuffer.IsReadOnly Method (Span, Boolean)

Determines whether a text modification or deletion would be prohibited at span due to an IReadOnlyRegion.

Namespace:  Microsoft.VisualStudio.Text
Assembly:  Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)

Syntax

‘선언
Function IsReadOnly ( _
    span As Span, _
    isEdit As Boolean _
) As Boolean
bool IsReadOnly(
    Span span,
    bool isEdit
)
bool IsReadOnly(
    Span span, 
    bool isEdit
)
abstract IsReadOnly : 
        span:Span * 
        isEdit:bool -> bool 
function IsReadOnly(
    span : Span, 
    isEdit : boolean
) : boolean

Parameters

  • isEdit
    Type: System.Boolean
    true if this check is part of an edit. false for a query without side effects.

Return Value

Type: System.Boolean
true if the entire span could be deleted or replaced, false otherwise.

Exceptions

Exception Condition
ArgumentNullException

span is nulla null reference (Nothing in Visual Basic).

InvalidOperationException

TakeThreadOwnership has previously been called, and this call is being made from a different thread.

ArgumentOutOfRangeException

The End property of span is greater than the length of CurrentSnapshot.

.NET Framework Security

See Also

Reference

ITextBuffer Interface

IsReadOnly Overload

Microsoft.VisualStudio.Text Namespace