Share via


CodeGeneratorContext.AddStatement Method (String, CodeLinePragma)

This type/member supports the .NET Framework infrastructure and is not intended to be used directly from your code. Adds the specified code statement to the body of the target method.

Namespace:  System.Web.Razor.Generator
Assembly:  System.Web.Razor (in System.Web.Razor.dll)

Syntax

'Declaration
Public Sub AddStatement ( _
    body As String, _
    pragma As CodeLinePragma _
)
'Usage
Dim instance As CodeGeneratorContext 
Dim body As String 
Dim pragma As CodeLinePragma

instance.AddStatement(body, pragma)
public void AddStatement(
    string body,
    CodeLinePragma pragma
)
public:
void AddStatement(
    String^ body, 
    CodeLinePragma^ pragma
)
member AddStatement : 
        body:string * 
        pragma:CodeLinePragma -> unit
public function AddStatement(
    body : String, 
    pragma : CodeLinePragma
)

Parameters

  • body
    Type: System.String
    The code statement to add the target method.

See Also

Reference

CodeGeneratorContext Class

AddStatement Overload

System.Web.Razor.Generator Namespace