Lines Matching refs:dest

35 bool EscapeSpecialCodePoint(uint32_t code_point, std::string* dest) {  in EscapeSpecialCodePoint()  argument
41 dest->append("\\b"); in EscapeSpecialCodePoint()
44 dest->append("\\f"); in EscapeSpecialCodePoint()
47 dest->append("\\n"); in EscapeSpecialCodePoint()
50 dest->append("\\r"); in EscapeSpecialCodePoint()
53 dest->append("\\t"); in EscapeSpecialCodePoint()
56 dest->append("\\\\"); in EscapeSpecialCodePoint()
59 dest->append("\\\""); in EscapeSpecialCodePoint()
64 dest->append("\\u003C"); in EscapeSpecialCodePoint()
69 dest->append("\\u2028"); in EscapeSpecialCodePoint()
72 dest->append("\\u2029"); in EscapeSpecialCodePoint()
81 bool EscapeJSONStringImpl(const S& str, bool put_in_quotes, std::string* dest) { in EscapeJSONStringImpl() argument
85 dest->push_back('"'); in EscapeJSONStringImpl()
99 if (EscapeSpecialCodePoint(code_point, dest)) in EscapeJSONStringImpl()
104 base::StringAppendF(dest, kU16EscapeFormat, code_point); in EscapeJSONStringImpl()
106 WriteUnicodeCharacter(code_point, dest); in EscapeJSONStringImpl()
110 dest->push_back('"'); in EscapeJSONStringImpl()
119 std::string* dest) { in EscapeJSONString() argument
120 return EscapeJSONStringImpl(str, put_in_quotes, dest); in EscapeJSONString()
125 std::string* dest) { in EscapeJSONString() argument
126 return EscapeJSONStringImpl(str, put_in_quotes, dest); in EscapeJSONString()
130 std::string dest; in GetQuotedJSONString() local
131 bool ok = EscapeJSONStringImpl(str, true, &dest); in GetQuotedJSONString()
133 return dest; in GetQuotedJSONString()
137 std::string dest; in GetQuotedJSONString() local
138 bool ok = EscapeJSONStringImpl(str, true, &dest); in GetQuotedJSONString()
140 return dest; in GetQuotedJSONString()
145 std::string dest; in EscapeBytesAsInvalidJSONString() local
148 dest.push_back('"'); in EscapeBytesAsInvalidJSONString()
152 if (EscapeSpecialCodePoint(c, &dest)) in EscapeBytesAsInvalidJSONString()
156 base::StringAppendF(&dest, kU16EscapeFormat, c); in EscapeBytesAsInvalidJSONString()
158 dest.push_back(*it); in EscapeBytesAsInvalidJSONString()
162 dest.push_back('"'); in EscapeBytesAsInvalidJSONString()
164 return dest; in EscapeBytesAsInvalidJSONString()