writeLog is a wrapper for process.stdout.write() but can be mocked

@param {...Object} obj - objects to be printed to stdout
552996
function writeLog () {
  if (mocking) {
    cli.stdout += stripAnsi(concatArguments(arguments))
  } else {
    process.stdout.write.apply(process.stdout, arguments)
  }
}
246873
function writeLog(logLevel, writeArgs) {

        var logName = loggerName || 'ROOT';
        var levelAppenders = [];
        var logger;

        // child level always overwrite parent levels
        // if the child does not allow, no appender even parents' ones won't show
        if (getLevelNumber(thisLogger.getLevel()) <= getLevelNumber(logLevel)) {
            logger = thisLogger;
            while (logger) {
                levelAppenders = _.concat(levelAppenders, logger.getAppenders()); logger = logger.getParent();
            }
        }

        // write the message to each appender no more than once!
        _.uniq(levelAppenders).forEach(function (appender) {

            var fmt = appender.pattern.format(logName, logLevel, writeArgs[0], _.slice(writeArgs, 1));

            var args = _.concat(logName, logLevel, fmt.message);
            // any more arguments ?
            if (fmt.otherArgs) {
                args = _.concat(args, fmt.otherArgs);
            }
            appender.writeLog.apply(this, args);
        });
    }
886667
function log () {
  if (mocking) {
    cli.stdout += stripAnsi(concatArguments(arguments) + '\n')
  } else {
    console.log.apply(null, arguments)
  }
}
149431
function log(message, context) {
        if (defaults.debug) {
            console.log((typeof context === 'object') ? compile(message, context) : message)
        }
    }
567297
def write_object_to_file(self, obj, path='.', filename=None):
        """"""
        output = self.json_dumps(obj) + '\n'
        if filename is None:
            filename = self.safe_filename(obj['_type'], obj['_id'])
        filename = os.path.join(path, filename)
        self.pr_inf("Writing to file: " + filename)
        with open(filename, 'w') as f:
            f.write(output)
        # self.pr_dbg("Contents: " + output)
        return filename
402861
function writeLog(type, category){
    return function(messages) {
        var funcs = [];

        _.each(messages, function(message){
            funcs.push(this.client.logAsync(message, [type, category]));
        }.bind(this));

        return BB.all(funcs);
    };

}
276870
public long writeLogRecord(LogRecord logRecord)
                    throws ObjectManagerException
    {
        if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
            trace.entry(this, cclass
                        , "writeLogRecord"
                            );

        long logSequenceNumber = objectManagerState.logOutput.writeNext(logRecord
                                                                        , 0
                                                                        , true
                                                                        , false
                        );

        if (Tracing.isAnyTracingEnabled() && trace.isEntryEnabled())
            trace.exit(this, cclass
                       , "writeLogRecord"
                       , "returns logSequenceNumber=" + logSequenceNumber + "(long)"
                            );
        return logSequenceNumber;
    }
128834
@JSFunction
    public static void writeLine(Context cx, Scriptable thisObj,
                                            Object[] args, Function funObj)
        throws IOException
    {
        write0(thisObj, args, true);
    }
209326
public static void print(final Object obj)
	{
		System.out.println(getInstance(obj.getClass()).serialise(obj));
	}
329353
function scriptLog(script, msg, isError) {
	write(msg, 
		isError ? clc.red : null, 
		clc.yellow('[' + script + ']'));
}
864904
function outputToStdout(prettyPrint) {
  if (prettyPrint && !_.isNumber(prettyPrint)) {
    prettyPrint = 4;
  }
  return function(err, value, callback) {
    if (err) {
      console.error(err);
    } else {
      var str = JSON.stringify(value, null, prettyPrint);
      console.log(str);
    }
    callback(err, value);
  };
}
70951
function writeLogFile(file, line) {
     
    if (file === undefined || file === null) {
        return;
    }
    
    fs.appendFile(file, line + os.EOL, {}, function() {
        //
    });
}
1041307
public static boolean writeObjectToFile(Object obj, File f) {
        try {
            FileOutputStream fout = new FileOutputStream(f);
            ObjectOutputStream oos = new ObjectOutputStream(fout);
            oos.writeObject(obj);
            oos.close();
        } catch (Exception e) {
            System.out.println("Error writing Object to file: "
                    + e.getMessage());
            return false;
        }
        return true;
    }
408339
def writeProxy(self, obj):
        
        proxy = self.context.getProxyForObject(obj)

        self.writeObject(proxy, is_proxy=True)
108210
public void print(Object obj) throws IOException {

        if (mOut != null) {
            // static Tea!
            mOut.write(toString(obj));
        }
    }
347031
function _log() {
  var args = Array.prototype.slice.call(arguments, 0),
    level = args.shift();

  if (!~['log', 'error', 'warn'].indexOf(level)) {
    args.unshift(level);
    level = 'log';
  }

  if (level == 'log') {
    args[0] = '----> ' + args[0];
  } else if (level == 'error') {
    args[0] = '....> ' + colors.red('ERROR: ') + args[0];
  } else if (level == 'warn') {
    args[0] = '....> ' + colors.yellow('WARNING: ') + args[0];
  }

  console[level].apply(console, args);
}
961658
@Override
    public void writeObject(Object obj, AbstractHessianOutput out)
        throws IOException
    {
        if (out.addRef(obj)) {
            return;
        }

        int ref = out.writeObjectBegin(getClassName(obj));

        if (ref < -1) {
            out.writeString("value");

            InputStream is = null;

            try {
                is = getInputStream(obj);
            } catch (Exception e) {
                log.log(Level.WARNING, e.toString(), e);
            }

            if (is != null) {
                try {
                    out.writeByteStream(is);
                } finally {
                    is.close();
                }
            } else {
                out.writeNull();
            }

            out.writeMapEnd();
        }
        else {
            if (ref == -1) {
                out.writeClassFieldLength(1);
                out.writeString("value");

                out.writeObjectBegin(getClassName(obj));
            }

            InputStream is = null;

            try {
                is = getInputStream(obj);
            } catch (Exception e) {
                log.log(Level.WARNING, e.toString(), e);
            }

            try {
                if (is != null)
                    out.writeByteStream(is);
                else
                    out.writeNull();
            } finally {
                if (is != null)
                    is.close();
            }
        }
    }