Esempio n. 1
0
        public void Log(FirebugConsoleMessageStyle style, object[] objects)
        {
            // Convert the objects to a string.
            var message = new StringBuilder();

            for (int i = 0; i < objects.Length; i++)
            {
                message.Append(' ');
                message.Append(TypeConverter.ToString(objects[i]));
            }

            switch (style)
            {
            case FirebugConsoleMessageStyle.Regular:
            case FirebugConsoleMessageStyle.Information:
            case FirebugConsoleMessageStyle.Warning:
                _output.Log(message.ToString());
                break;

            case FirebugConsoleMessageStyle.Error:
                _output.Error(message.ToString());
                break;

            default:
                throw new ArgumentOutOfRangeException("style");
            }
        }
Esempio n. 2
0
        public void Log(params JsValue[] objects)
        {
            // Convert the objects to a string.
            var message = new StringBuilder();

            foreach (var t in objects)
            {
                message.Append(' ');
                message.Append(t);
            }

            _output.Log(message.ToString());
        }