2 overrides of EventDeclaration
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
CodeGeneration\CSharpSyntaxGenerator.cs (1)
531
public override SyntaxNode
EventDeclaration
(
Microsoft.CodeAnalysis.VisualBasic.Workspaces (1)
CodeGeneration\VisualBasicSyntaxGenerator.vb (1)
3211
Public Overrides Function
EventDeclaration
(name As String, type As SyntaxNode, Optional accessibility As Accessibility = Accessibility.NotApplicable, Optional modifiers As DeclarationModifiers = Nothing) As SyntaxNode
27 references to EventDeclaration
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (15)
CodeGeneration\SyntaxGeneratorTests.cs (15)
1134
Generator.
EventDeclaration
("ef", Generator.IdentifierName("t")),
1138
Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), accessibility: Accessibility.Public),
1142
Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), modifiers: DeclarationModifiers.Static),
1654
Generator.InterfaceDeclaration("i", members: [Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), accessibility: Accessibility.Public, modifiers: DeclarationModifiers.Static)]),
1888
Generator.
EventDeclaration
("ef", Generator.IdentifierName("t")),
2886
Assert.Equal(DeclarationKind.Event, Generator.GetDeclarationKind(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"))));
2909
Assert.Equal("ef", Generator.GetName(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"))));
2932
Assert.Equal("ef", Generator.GetName(Generator.WithName(Generator.
EventDeclaration
("x", Generator.IdentifierName("t")), "ef")));
2955
Assert.Equal(Accessibility.Internal, Generator.GetAccessibility(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), accessibility: Accessibility.Internal)));
2979
Assert.Equal(Accessibility.Private, Generator.GetAccessibility(Generator.WithAccessibility(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), accessibility: Accessibility.Internal), Accessibility.Private)));
3002
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), modifiers: DeclarationModifiers.Static)));
3025
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.WithModifiers(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t")), DeclarationModifiers.Static)));
3086
Generator.GetModifiers(Generator.WithModifiers(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t")), allModifiers)));
3202
Assert.Equal("t", Generator.GetType(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"))).ToString());
3225
Assert.Equal("t", Generator.GetType(Generator.WithType(Generator.
EventDeclaration
("ef", Generator.IdentifierName("x")), Generator.IdentifierName("t"))).ToString());
Microsoft.CodeAnalysis.VisualBasic.Workspaces.UnitTests (11)
CodeGeneration\SyntaxGeneratorTests.vb (11)
1333
Generator.
EventDeclaration
("ev", Generator.IdentifierName("t")),
1337
Generator.
EventDeclaration
("ev", Generator.IdentifierName("t"), accessibility:=Accessibility.Public, modifiers:=DeclarationModifiers.Static),
2581
Assert.Equal(DeclarationKind.Event, Generator.GetDeclarationKind(Generator.
EventDeclaration
("e", Generator.IdentifierName("t"))))
2606
Assert.Equal("ef", Generator.GetName(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"))))
2631
Assert.Equal("ef", Generator.GetName(Generator.WithName(Generator.
EventDeclaration
("x", Generator.IdentifierName("t")), "ef")))
2653
Assert.Equal(Accessibility.Internal, Generator.GetAccessibility(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), accessibility:=Accessibility.Internal)))
2681
Assert.Equal(Accessibility.Private, Generator.GetAccessibility(Generator.WithAccessibility(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), accessibility:=Accessibility.Internal), Accessibility.Private)))
2707
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"), modifiers:=DeclarationModifiers.Static)))
2729
Assert.Equal(DeclarationModifiers.Static, Generator.GetModifiers(Generator.WithModifiers(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t")), DeclarationModifiers.Static)))
2772
Assert.Equal("t", Generator.GetType(Generator.
EventDeclaration
("ef", Generator.IdentifierName("t"))).ToString())
2796
Assert.Equal("t", Generator.GetType(Generator.WithType(Generator.
EventDeclaration
("ef", Generator.IdentifierName("x")), Generator.IdentifierName("t"))).ToString())
Microsoft.CodeAnalysis.Workspaces (1)
Editing\SyntaxGenerator.cs (1)
492
var ev =
EventDeclaration
(