Пример #1
0
        internal CommandLineRunner(ConsoleIO console, CommonCompiler compiler, ScriptCompiler scriptCompiler, ObjectFormatter objectFormatter)
        {
            Debug.Assert(console != null);
            Debug.Assert(compiler != null);
            Debug.Assert(scriptCompiler != null);
            Debug.Assert(objectFormatter != null);

            _console         = console;
            _compiler        = compiler;
            _scriptCompiler  = scriptCompiler;
            _objectFormatter = objectFormatter;
        }
Пример #2
0
        internal CommandLineRunner(ConsoleIO console, CommonCompiler compiler, ScriptCompiler scriptCompiler, ObjectFormatter objectFormatter)
        {
            Debug.Assert(console != null);
            Debug.Assert(compiler != null);
            Debug.Assert(scriptCompiler != null);
            Debug.Assert(objectFormatter != null);

            _console = console;
            _compiler = compiler;
            _scriptCompiler = scriptCompiler;
            _objectFormatter = objectFormatter;
        }
Пример #3
0
        // TODO (tomat): Add ReferencePaths, SourcePaths

        internal CommandLineHostObject(TextWriter outputWriter, ObjectFormatter objectFormatter, CancellationToken cancellationToken)
        {
            CancellationToken = cancellationToken;

            _formattingOptions = new ObjectFormattingOptions(
                memberFormat: MemberDisplayFormat.Inline,
                quoteStrings: true,
                useHexadecimalNumbers: false,
                maxOutputLength: 1024,
                memberIndentation: "  ");

            _outputWriter    = outputWriter;
            _objectFormatter = objectFormatter;
        }
Пример #4
0
        // TODO (tomat): Add ReferencePaths, SourcePaths

        internal CommandLineHostObject(TextWriter outputWriter, ObjectFormatter objectFormatter, CancellationToken cancellationToken)
        {
            CancellationToken = cancellationToken;

            _formattingOptions = new ObjectFormattingOptions(
                memberFormat: MemberDisplayFormat.Inline,
                quoteStrings: true,
                useHexadecimalNumbers: false,
                maxOutputLength: 1024,
                memberIndentation: "  ");

            _outputWriter = outputWriter;
            _objectFormatter = objectFormatter;
        }
Пример #5
0
        public CommandLineScriptGlobals(TextWriter outputWriter, ObjectFormatter objectFormatter)
        {
            if (outputWriter == null)
            {
                throw new ArgumentNullException(nameof(outputWriter));
            }

            if (objectFormatter == null)
            {
                throw new ArgumentNullException(nameof(objectFormatter));
            }

            PrintOptions = new PrintOptions();

            _outputWriter    = outputWriter;
            _objectFormatter = objectFormatter;

            Args = new List <string>();
        }
        public CommandLineScriptGlobals(TextWriter outputWriter, ObjectFormatter objectFormatter)
        {
            if (outputWriter == null)
            {
                throw new ArgumentNullException(nameof(outputWriter));
            }

            if (objectFormatter == null)
            {
                throw new ArgumentNullException(nameof(objectFormatter));
            }

            PrintOptions = ObjectFormattingOptions.Default;

            _outputWriter = outputWriter;
            _objectFormatter = objectFormatter;

            Args = new List<string>();
        }
        public InteractiveScriptGlobals(TextWriter outputWriter, ObjectFormatter objectFormatter)
        {
            if (outputWriter == null)
            {
                throw new ArgumentNullException(nameof(outputWriter));
            }

            if (objectFormatter == null)
            {
                throw new ArgumentNullException(nameof(objectFormatter));
            }

            Debug.Assert(outputWriter != null);
            Debug.Assert(objectFormatter != null);

            ReferencePaths = new SearchPaths();
            SourcePaths = new SearchPaths();
            Args = new List<string>();

            PrintOptions = ObjectFormattingOptions.Default;
            _outputWriter = outputWriter;
            _objectFormatter = objectFormatter;
        }
        public InteractiveScriptGlobals(TextWriter outputWriter, ObjectFormatter objectFormatter)
        {
            if (outputWriter == null)
            {
                throw new ArgumentNullException(nameof(outputWriter));
            }

            if (objectFormatter == null)
            {
                throw new ArgumentNullException(nameof(objectFormatter));
            }

            Debug.Assert(outputWriter != null);
            Debug.Assert(objectFormatter != null);

            ReferencePaths = new SearchPaths();
            SourcePaths    = new SearchPaths();
            Args           = new List <string>();

            PrintOptions     = ObjectFormattingOptions.Default;
            _outputWriter    = outputWriter;
            _objectFormatter = objectFormatter;
        }
 public InteractiveScriptGlobals(TextWriter outputWriter, ObjectFormatter objectFormatter)
 {
     this._objectFormatter = objectFormatter;
     this._outputWriter = outputWriter;
 }
 public Formatter(ObjectFormatter language, ObjectFormattingOptions options)
 {
     _options = options ?? ObjectFormattingOptions.Default;
     _language = language;
 }
Пример #11
0
 public Formatter(ObjectFormatter language, ObjectFormattingOptions options)
 {
     _options  = options ?? ObjectFormattingOptions.Default;
     _language = language;
 }