protected static byte escape()

in gflog-core/src/main/java/com/epam/deltix/gflog/core/layout/GelfLayout.java [159:184]


    protected static byte escape(final byte b) {
        switch (b) {
            case '\b':
                return 'b';

            case '\f':
                return 'f';

            case '\n':
                return 'n';

            case '\r':
                return 'r';

            case '\t':
                return 't';

            case '"':
            case '\\':
            case '/':
                return b;

            default:
                return 0;
        }
    }