class ChannelLogDescriptor {

    static String logDescriptor(Channel channel) {<FILL_FUNCTION_BODY>}

    static String getId(Channel channel) {
        return String.format("0x%08x", channel.hashCode());
    }

}


        if (channel == null) {
            return "unknown";
        }

        StringBuffer buffer = new StringBuffer(64);

        buffer.append("channel=").append(getId(channel)).append(", ");

        if (channel.localAddress() != null && channel.remoteAddress() != null) {
            buffer.append(channel.localAddress()).append(" -> ").append(channel.remoteAddress());
        } else {
            buffer.append(channel);
        }

        if (!channel.isActive()) {
            if (buffer.length() != 0) {
                buffer.append(' ');
            }

            buffer.append("(inactive)");
        }

        return buffer.toString();
    
<no_super_class>