Package com.alibaba.citrus.util

Examples of com.alibaba.citrus.util.ToStringBuilder.format()


            if (isDefaultPattern()) {
                buf.format("match=\"*\", store=\"%s\"", storeName);
            } else if (isRegexPattern()) {
                buf.format("match=~/%s/, store=\"%s\"", patternName, storeName);
            } else {
                buf.format("match=\"%s\", store=\"%s\"", patternName, storeName);
            }

            return buf.toString();
        }
    }
View Full Code Here


        Collections.sort(cookiesInfo.cookieList);

        if (log.isDebugEnabled()) {
            ToStringBuilder buf = new ToStringBuilder();

            buf.format("[%s] Loading cookies: %d cookies found", getStoreName(), cookiesInfo.cookieList.size());

            if (isEmptyArray(cookiesInfo.checksumList)) {
                if (checksum) {
                    buf.append("\n No checksum cookie");
                }
View Full Code Here

            if (isEmptyArray(cookiesInfo.checksumList)) {
                if (checksum) {
                    buf.append("\n No checksum cookie");
                }
            } else {
                buf.format("\n %s[expected cookies=%d]=%s", checksumName, cookiesInfo.checksumList.length,
                           ObjectUtil.toString(cookiesInfo.checksumList));
            }

            for (CookieInfo cookieInfo : cookiesInfo.cookieList) {
                int length = 0;
View Full Code Here

                if (cookieInfo.value != null) {
                    length = cookieInfo.value.length();
                }

                buf.format("\n %s[length=%d]=%s", cookieInfo.name, length, cookieInfo.value);
            }

            log.debug(buf.toString());
        }
View Full Code Here

                buf.append("Failed to decode cookie value: ").append(cookieValue);

                int i = 0;
                for (Exception e : encoderExceptions) {
                    buf.format("\n  Encoder #%d - %s threw %s", i + 1, encoders[i].getClass().getSimpleName(), e);
                }

                log.warn(buf.toString());
            }
        } else {
View Full Code Here

        } else {
            if (log.isDebugEnabled()) {
                int attrCount = attrs.size();
                ToStringBuilder buf = new ToStringBuilder();

                buf.format("Found %d attributes:", attrCount);

                if (!attrs.isEmpty()) {
                    buf.append(new MapBuilder().setPrintCount(true).setSortKeys(true).appendAll(attrs));
                }
View Full Code Here

    @Override
    public String toString() {
        ToStringBuilder buf = new ToStringBuilder();

        buf.format("Schemas[");

        if (mainSchema == null) {
            buf.format("missing main schema");
        } else if (mainSchema.getTargetNamespace() == null) {
            buf.format("%s", mainSchema.getName());
View Full Code Here

        ToStringBuilder buf = new ToStringBuilder();

        buf.format("Schemas[");

        if (mainSchema == null) {
            buf.format("missing main schema");
        } else if (mainSchema.getTargetNamespace() == null) {
            buf.format("%s", mainSchema.getName());
        } else {
            buf.format("%s, targetNamespace=%s", mainSchema.getName(), mainSchema.getTargetNamespace());
        }
View Full Code Here

        buf.format("Schemas[");

        if (mainSchema == null) {
            buf.format("missing main schema");
        } else if (mainSchema.getTargetNamespace() == null) {
            buf.format("%s", mainSchema.getName());
        } else {
            buf.format("%s, targetNamespace=%s", mainSchema.getName(), mainSchema.getTargetNamespace());
        }

        buf.format(", %d versioned schemas]", getVersions().length).start();
View Full Code Here

        if (mainSchema == null) {
            buf.format("missing main schema");
        } else if (mainSchema.getTargetNamespace() == null) {
            buf.format("%s", mainSchema.getName());
        } else {
            buf.format("%s, targetNamespace=%s", mainSchema.getName(), mainSchema.getTargetNamespace());
        }

        buf.format(", %d versioned schemas]", getVersions().length).start();

        for (String version : getVersions()) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.