protected boolean checkEntryConditions() {
        if (this.closed) {
            LogLog.warn("Not allowed to write to a closed appender.");
            return false;
        }

        if (this.out == null) {
            LogLog.error("No output stream or file set for the appender named [" + this.name + "].");
            return false;
        }

        if (this.layout == null) {
            LogLog.error("No layout set for the appender named [" + this.name + "].");
            return false;
        }
        return true;
    }
This method determines if there is a sense in attempting to append.

<p>
It checks whether there is a set output target and also if there is a set
layout. If these checks fail, then the boolean value <code>false</code>
is returned.
metamorphosis-client-extension/src/main/java/com/taobao/metamorphosis/client/extension/log4j/StreamAppender.java