public ICodeWriter Scope(ScopeIdentifier scopeIdentifier) { switch (scopeIdentifier) { case ScopeIdentifier.Public: Write(CSharpKeyword.Public); break; case ScopeIdentifier.Internal: Write(CSharpKeyword.Internal); break; case ScopeIdentifier.Protected: Write(CSharpKeyword.Protected); break; case ScopeIdentifier.Private: Write(CSharpKeyword.Private); break; default: throw new InvalidOperationException($"Unimplemented scope identifier {scopeIdentifier}"); } return(this); }
public RompScopedLogger(RompExecutionEnvironment executer, ScopeIdentifier current, ActiveNamedScope parent, IEnumerable <IMessage> initialMessages = null) : base(current, parent) { this.executer = executer; this.initialMessages = initialMessages; }
public ActiveNamedScope CreateLogScope(ScopeIdentifier current, ActiveNamedScope parent) => new RompScopedLogger(this, current, parent);