@Override public LoggingAdvisingAppendable appendLoggingFunctionInvocation( LoggingFunctionInvocation funCall, ImmutableList<Function<String, String>> escapers) throws IOException { return append(escapePlaceholder(funCall.placeholderValue(), escapers)); } };
@Override public void render(LoggingAdvisingAppendable appendable) throws IOException { appendable .setSanitizedContentKind(getContentKind()) .setSanitizedContentDirectionality(getContentDirection()) .append(content); }
/** * Precondition: The specified index contains a string. Gets the string at the given index. * * @param index The index. * @return The string at the given index, or null of the index is undefined. */ public String getString(int index) { return get(index).stringValue(); }
/** Creates a SanitizedContent object with default direction. */ static SanitizedContent create(String content, ContentKind kind) { checkArgument( kind != ContentKind.TEXT, "Use UnsanitizedString for SanitizedContent with a kind of TEXT"); if (Flags.stringIsNotSanitizedContent()) { return new SanitizedContent(content, kind, kind.getDefaultDir()); } return SanitizedCompatString.create(content, kind, kind.getDefaultDir()); }
@Override public void render(LoggingAdvisingAppendable appendable) throws IOException { appendable .setSanitizedContentKind(getContentKind()) .setSanitizedContentDirectionality(getContentDirection()) .append(content); }
/** * Precondition: The specified index contains a float. Gets the float at the given index. * * @param index The index. * @return The float at the given index, or null of the index is undefined. */ public double getFloat(int index) { return get(index).floatValue(); }
/** * Precondition: The specified index contains an integer. Gets the integer at the given index. * * @param index The index. * @return The integer at the given index, or null of the index is undefined. */ public int getInteger(int index) { return get(index).integerValue(); }
/** * Precondition: The specified index contains a boolean. Gets the boolean at the given index. * * @param index The index. * @return The boolean at the given index, or null of the index is undefined. */ public boolean getBoolean(int index) { return get(index).booleanValue(); }
@Override public SoyValueProvider apply(SoyGlobalsValue input) { return convert(input.getSoyGlobalValue()); } });
@Override public LoggingAdvisingAppendable exitLoggableElement() { delegate.exitLoggableElement(); buffer.exitLoggableElement(); return this; }
@Override protected void notifyContentKind(ContentKind kind) throws IOException { delegate.setSanitizedContentKind(kind); buffer.setSanitizedContentKind(kind); }
@Override public LoggingAdvisingAppendable appendLoggingFunctionInvocation( LoggingFunctionInvocation funCall, ImmutableList<Function<String, String>> escapers) throws IOException { delegate.appendLoggingFunctionInvocation(funCall, escapers); buffer.appendLoggingFunctionInvocation(funCall, escapers); return this; } }
/** Creates a SanitizedContent object with default direction. */ static SanitizedCompatString create(String content, ContentKind kind) { return new SanitizedCompatString(content, kind, kind.getDefaultDir()); } }
@Override protected void doAppendLoggingFunctionInvocation( LoggingFunctionInvocation funCall, ImmutableList<Function<String, String>> escapers) throws IOException { escapePlaceholder(funCall.placeholderValue(), escapers); }
private ProtoFieldInterpreter impl() { ProtoFieldInterpreter local = interpreter; if (local == null) { local = ProtoFieldInterpreter.create(getDescriptor()); } return local; }
/** * Precondition: The specified index contains a float. Gets the float at the given index. * * @param index The index. * @return The float at the given index, or null of the index is undefined. */ public double getFloat(int index) { return get(index).floatValue(); }
@Override public SoyValueProvider apply(SoyGlobalsValue input) { return convert(input.getSoyGlobalValue()); } });