protected SyntaxNode CreateTypeDeclaration(
            SyntaxNode containerNode,
            TypeKind typeKind,
            string name,
            EnvDTE.vsCMAccess access,
            INamedTypeSymbol baseType = null,
            ImmutableArray <INamedTypeSymbol> implementedInterfaces = default(ImmutableArray <INamedTypeSymbol>))
        {
            var destination = CodeModelService.GetDestination(containerNode);

            var newTypeSymbol = CodeGenerationSymbolFactory.CreateNamedTypeSymbol(
                attributes: default(ImmutableArray <AttributeData>),
                accessibility: CodeModelService.GetAccessibility(access, SymbolKind.NamedType, destination),
                modifiers: new DeclarationModifiers(),
                typeKind: typeKind,
                name: name,
                typeParameters: default(ImmutableArray <ITypeParameterSymbol>),
                baseType: baseType,
                interfaces: implementedInterfaces,
                specialType: SpecialType.None,
                members: default(ImmutableArray <ISymbol>));

            return(CodeGenerationService.CreateNamedTypeDeclaration(
                       newTypeSymbol, destination,
                       options: GetCodeGenerationOptions(access, containerNode.SyntaxTree.Options)));
        }
        protected SyntaxNode CreateDelegateTypeDeclaration(SyntaxNode containerNode, string name, EnvDTE.vsCMAccess access, INamedTypeSymbol returnType)
        {
            var destination = CodeModelService.GetDestination(containerNode);

            var newTypeSymbol = CodeGenerationSymbolFactory.CreateDelegateTypeSymbol(
                attributes: null,
                accessibility: CodeModelService.GetAccessibility(access, SymbolKind.NamedType, destination),
                modifiers: new DeclarationModifiers(),
                returnType: returnType,
                name: name);

            return(CodeGenerationService.CreateNamedTypeDeclaration(
                       newTypeSymbol, destination,
                       options: GetCodeGenerationOptions(access)));
        }