|
2 | 2 |
|
3 | 3 | import java.lang.ref.SoftReference;
|
4 | 4 |
|
| 5 | +import com.fasterxml.jackson.core.io.JsonStringEncoder; |
| 6 | + |
5 | 7 | /**
|
6 | 8 | * Helper entity used to control access to simple buffer recyling scheme used for
|
7 | 9 | * some encoding, decoding tasks.
|
@@ -96,4 +98,70 @@ public static int releaseBuffers() {
|
96 | 98 | }
|
97 | 99 | return -1;
|
98 | 100 | }
|
| 101 | + |
| 102 | + /* |
| 103 | + /********************************************************************** |
| 104 | + /* Obsolete things re-introduced in 2.12.5 after accidental direct |
| 105 | + /* removal from 2.10.0 |
| 106 | + /********************************************************************** |
| 107 | + */ |
| 108 | + |
| 109 | + /** |
| 110 | + * Not to be used any more: call {@link JsonStringEncoder#getInstance()} instead. |
| 111 | + * |
| 112 | + * @deprecated Since 2.10 (note: was accidentally removed but reintroduced as deprecated |
| 113 | + * in 2.12.5, to be removed from 3.0) |
| 114 | + */ |
| 115 | + @Deprecated |
| 116 | + public static JsonStringEncoder getJsonStringEncoder() { |
| 117 | + return JsonStringEncoder.getInstance(); |
| 118 | + } |
| 119 | + |
| 120 | + /** |
| 121 | + * Not to be used any more: call {@link JsonStringEncoder#getInstance()} (and then |
| 122 | + * {@code encodeAsUTF8()}) instead. |
| 123 | + * |
| 124 | + * @deprecated Since 2.10 (note: was accidentally removed but reintroduced as deprecated |
| 125 | + * in 2.12.5, to be removed from 3.0) |
| 126 | + */ |
| 127 | + @Deprecated |
| 128 | + public static byte[] encodeAsUTF8(String text) { |
| 129 | + return JsonStringEncoder.getInstance().encodeAsUTF8(text); |
| 130 | + } |
| 131 | + |
| 132 | + /** |
| 133 | + * Not to be used any more: call {@link JsonStringEncoder#getInstance()} (and then |
| 134 | + * {@code quoteAsString()}) instead. |
| 135 | + * |
| 136 | + * @deprecated Since 2.10 (note: was accidentally removed but reintroduced as deprecated |
| 137 | + * in 2.12.5, to be removed from 3.0) |
| 138 | + */ |
| 139 | + @Deprecated |
| 140 | + public static char[] quoteAsJsonText(String rawText) { |
| 141 | + return JsonStringEncoder.getInstance().quoteAsString(rawText); |
| 142 | + } |
| 143 | + |
| 144 | + /** |
| 145 | + * Not to be used any more: call {@link JsonStringEncoder#getInstance()} (and then |
| 146 | + * {@code quoteAsString()}) instead. |
| 147 | + * |
| 148 | + * @deprecated Since 2.10 (note: was accidentally removed but reintroduced as deprecated |
| 149 | + * in 2.12.5, to be removed from 3.0) |
| 150 | + */ |
| 151 | + @Deprecated |
| 152 | + public static void quoteAsJsonText(CharSequence input, StringBuilder output) { |
| 153 | + JsonStringEncoder.getInstance().quoteAsString(input, output); |
| 154 | + } |
| 155 | + |
| 156 | + /** |
| 157 | + * Not to be used any more: call {@link JsonStringEncoder#getInstance()} (and then |
| 158 | + * {@code quoteAsUTF8()}) instead. |
| 159 | + * |
| 160 | + * @deprecated Since 2.10 (note: was accidentally removed but reintroduced as deprecated |
| 161 | + * in 2.12.5, to be removed from 3.0) |
| 162 | + */ |
| 163 | + @Deprecated |
| 164 | + public static byte[] quoteAsJsonUTF8(String rawText) { |
| 165 | + return JsonStringEncoder.getInstance().quoteAsUTF8(rawText); |
| 166 | + } |
99 | 167 | }
|
0 commit comments