public static ClassDeclarationSyntax CreateAsInternalStatic(string classTypeName) { if (classTypeName == null) { throw new ArgumentNullException(nameof(classTypeName)); } return(SyntaxFactory.ClassDeclaration(classTypeName) .AddModifiers(SyntaxTokenFactory.InternalKeyword(), SyntaxTokenFactory.StaticKeyword())); }
public static SyntaxTokenList ProtectedStaticKeyword(bool withLeadingLineFeed = false, bool withTrailingSpace = true) { if (withLeadingLineFeed) { return(SyntaxFactory.TokenList( SyntaxTokenFactory.CarriageReturnLineFeed(), SyntaxTokenFactory.ProtectedKeyword(), SyntaxTokenFactory.StaticKeyword(withTrailingSpace))); } return(SyntaxFactory.TokenList( SyntaxTokenFactory.ProtectedKeyword(), SyntaxTokenFactory.StaticKeyword(withTrailingSpace))); }