Sdílet prostřednictvím


CSharpMigrationCodeGenerator.WriteClassStart Metoda

Definice

Přetížení

WriteClassStart(String, String, IndentedTextWriter, String, Boolean, IEnumerable<String>)

Generuje obor názvů pomocí příkazů a definice třídy.

WriteClassStart(String, String, IndentedTextWriter, String, Boolean)

Generuje obor názvů pomocí příkazů a definice třídy.

WriteClassStart(String, String, IndentedTextWriter, String, Boolean, IEnumerable<String>)

Generuje obor názvů pomocí příkazů a definice třídy.

protected virtual void WriteClassStart(string namespace, string className, System.Data.Entity.Migrations.Utilities.IndentedTextWriter writer, string base, bool designer = false, System.Collections.Generic.IEnumerable<string> namespaces = null);
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1026:DefaultParametersShouldNotBeUsed")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId="namespace")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Naming", "CA1716:IdentifiersShouldNotMatchKeywords", MessageId="base")]
protected virtual void WriteClassStart(string namespace, string className, System.Data.Entity.Migrations.Utilities.IndentedTextWriter writer, string base, bool designer = false, System.Collections.Generic.IEnumerable<string> namespaces = null);
abstract member WriteClassStart : string * string * System.Data.Entity.Migrations.Utilities.IndentedTextWriter * string * bool * seq<string> -> unit
override this.WriteClassStart : string * string * System.Data.Entity.Migrations.Utilities.IndentedTextWriter * string * bool * seq<string> -> unit
Protected Overridable Sub WriteClassStart (namespace As String, className As String, writer As IndentedTextWriter, base As String, Optional designer As Boolean = false, Optional namespaces As IEnumerable(Of String) = null)

Parametry

namespace
String

Obor názvů, ve kterém by měl být vygenerován kód.

className
String

Název třídy, která má být generována.

writer
IndentedTextWriter

Zapisovač textu, do který chcete přidat vygenerovaný kód.

base
String

Základní třída pro vygenerovanou třídu.

designer
Boolean

Hodnota označující, jestli je tato třída generována pro soubor kódu na pozadí.

namespaces
IEnumerable<String>

Obory názvů, pro které budou přidány direktivy using. Pokud je hodnota null, použijí se obory názvů vrácené z GetDefaultNamespaces.

Atributy

Platí pro

WriteClassStart(String, String, IndentedTextWriter, String, Boolean)

Generuje obor názvů pomocí příkazů a definice třídy.

protected virtual void WriteClassStart(string namespace, string className, System.Data.Entity.Migrations.Utilities.IndentedTextWriter writer, string base, bool designer = false);
abstract member WriteClassStart : string * string * System.Data.Entity.Migrations.Utilities.IndentedTextWriter * string * bool -> unit
override this.WriteClassStart : string * string * System.Data.Entity.Migrations.Utilities.IndentedTextWriter * string * bool -> unit
Protected Overridable Sub WriteClassStart (namespace As String, className As String, writer As IndentedTextWriter, base As String, Optional designer As Boolean = false)

Parametry

namespace
String

Obor názvů, ve kterém by měl být vygenerován kód.

className
String

Název třídy, která má být generována.

writer
IndentedTextWriter

Zapisovač textu, do který chcete přidat vygenerovaný kód.

base
String

Základní třída pro vygenerovanou třídu.

designer
Boolean

Hodnota označující, jestli je tato třída generována pro soubor kódu na pozadí.

Platí pro