Exemplo n.º 1
0
        public void Accept(ICodeFormatterVisitor visitor)
        {
            foreach (ICodeFormatterAcceptor acceptor in Model.VariableActionModel)
            {
                acceptor.Accept(visitor);
            }
            foreach (ICodeFormatterAcceptor acceptor in Model.MainActionModel)
            {
                acceptor.Accept(visitor);
            }
            Beautifier beautifier = new Beautifier();

            beautifier.Opts.IndentSize           = 4;
            beautifier.Opts.IndentChar           = ' ';
            beautifier.Opts.PreserveNewlines     = true;
            beautifier.Opts.JslintHappy          = false;
            beautifier.Opts.KeepArrayIndentation = false;
            beautifier.Opts.BraceStyle           = BraceStyle.Collapse;
            beautifier.Flags.IndentationLevel    = 0;
            beautifier.Opts.BreakChainedMethods  = false;
            CodeOutput = beautifier.Beautify(visitor.CodeOutput);
        }
Exemplo n.º 2
0
 public void Accept(ICodeFormatterVisitor visitor)
 {
     visitor.Visit(this);
 }