Package com.alibaba.citrus.util

Examples of com.alibaba.citrus.util.ToStringBuilder$MapBuilder


            mb.append("path", path);
            mb.append("maxAge", String.format("%,d seconds", maxAge));
            mb.append("httpOnly", httpOnly);
            mb.append("secure", secure);

            return new ToStringBuilder().append("CookieConfig").append(mb).toString();
        }
View Full Code Here


        mb.append("type", type);
        mb.append("annotations", annotations);
        mb.append("extraInfo", extraInfo);

        return new ToStringBuilder().append(getClass().getSimpleName()).append(mb).toString();
    }
View Full Code Here

        public String toString() {
            MapBuilder mb = new MapBuilder();

            mb.append("name", name);

            return new ToStringBuilder().append("UrlEncodeConfig").append(mb).toString();
        }
View Full Code Here

            }
        }

        @Override
        public String toString() {
            return new ToStringBuilder().append("Stores").append(stores).toString();
        }
View Full Code Here

                // 最长匹配优先
                Collections.sort(matches);

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

                    buf.format("Attribute \"%s\" ", attrName);

                    if (matches.isEmpty()) {
                        buf.append("does not match any pattern");
                    } else {
                        buf.append("matches the following CANDIDATED patterns:").append(matches);
                    }

                    log.trace(buf.toString());
                }

                if (!matches.isEmpty()) {
                    matchedStoreName = matches.get(0).pattern.getStoreName();
                }
View Full Code Here

        }

        // 如果失败,记录日志
        if (attrs.isEmpty() && encoderExceptions != null) {
            if (log.isWarnEnabled()) {
                ToStringBuilder buf = new ToStringBuilder();

                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 {
            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));
                }

                log.debug(buf.toString());
            }
        }

        return attrs;
    }
View Full Code Here

            return attrNames.toArray(new String[attrNames.size()]);
        }

        @Override
        public String toString() {
            return new ToStringBuilder().append("StoreMappings").append(patterns).toString();
        }
View Full Code Here

            return result;
        }

        @Override
        public String toString() {
            return new ToStringBuilder().append(pattern).append(", matchLength=").append(matchLength).toString();
        }
View Full Code Here

            return pattern;
        }

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

            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

                                mb.append(
                                        entry.getKey().getName(),
                                        getSimpleMethodSignature(entry.getValue().getJavaMethod(), false, true, true, false));
                            }

                            return new ToStringBuilder().append(intfs.getName()).append(mb).toString();
                        }
                    },

                    // proxied callback
                    new MethodInterceptor() {
View Full Code Here

TOP

Related Classes of com.alibaba.citrus.util.ToStringBuilder$MapBuilder

Copyright © 2018 www.massapicom. 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.