У меня есть строка, преобразованная из PDF с использованием EntityUtils.toString(httpResponse.getEntity())
. Как я могу преобразовать указанную выше строку обратно в PDF с помощью Java API в контроллере загрузки Spring? Ниже приведена строка, которую я получил после преобразования PDF в строку.
%PDF-1.4
%áâãä
1 0 obj
<<
/R8 2 0 R>>
endobj
2 0 obj
[ /Indexed /DeviceRGB 255
<000000FFFFFFBC9B6ABC9B6ABC9B6ABC9B6ABC9B6ABC9B6AFFFFFFBC9B6AFFFF
FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000>
]
endobj
3 0 obj
<<
/R7 4 0 R>>
endobj
4 0 obj
<<
/Type /ExtGState
/OPM 1>>
endobj
5 0 obj
<<
/R9 6 0 R>>
endobj
6 0 obj
<<
/Subtype /Image
/ColorSpace 2 0 R
/Width 201
/Height 201
/BitsPerComponent 8
/Filter /FlateDecode
/Length 1935>>
stream
xœí›Ù’ä(E#¼ãÿÿر‘`§]Ý1=£óTtÙdU)Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(Š¢(-õAó8uÛ êªêeHWåA7´iŽ>ìºÀ4F3v^΀µœŽÉž‡ÙV†LUtCæèîL£A† Lï¿ÊÓýÛ…ŒYkþF!3Yt»m¿œÐt˜ÐµiЖU“ó¹õiÖK=ŒŽµT©]q´6wѵŒjz“–vÉ
wm0gù/\•Ìz1<¿˜uŒ.ÅAÑ=·Ï=B]‡MP熥ñ4òBõÓdZË,¯J¼ÝJ-î¡lMÖ**