Share via


MethodBlockSyntax.WithSubOrFunctionStatement(MethodStatementSyntax) Method

Definition

Returns a copy of this with the SubOrFunctionStatement property changed to the specified value. Returns this instance if the specified value is the same as the current value.

public:
 Microsoft::CodeAnalysis::VisualBasic::Syntax::MethodBlockSyntax ^ WithSubOrFunctionStatement(Microsoft::CodeAnalysis::VisualBasic::Syntax::MethodStatementSyntax ^ subOrFunctionStatement);
public Microsoft.CodeAnalysis.VisualBasic.Syntax.MethodBlockSyntax WithSubOrFunctionStatement (Microsoft.CodeAnalysis.VisualBasic.Syntax.MethodStatementSyntax subOrFunctionStatement);
member this.WithSubOrFunctionStatement : Microsoft.CodeAnalysis.VisualBasic.Syntax.MethodStatementSyntax -> Microsoft.CodeAnalysis.VisualBasic.Syntax.MethodBlockSyntax
Public Function WithSubOrFunctionStatement (subOrFunctionStatement As MethodStatementSyntax) As MethodBlockSyntax

Parameters

subOrFunctionStatement
MethodStatementSyntax

Returns

Applies to