@groupdocs/groupdocs.conversion 23.10.0 → 23.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +2 -2
- package/lib/groupdocs.conversion.js +15 -25
- package/package.json +2 -2
package/index.js
CHANGED
|
@@ -11,8 +11,8 @@ const path = require('path');
|
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
if (!checkFileExists(path.join(__dirname, 'lib/groupdocs-conversion-nodejs-23.
|
|
15
|
-
console.warn('\x1b[33m%s\x1b[0m', `File groupdocs-conversion-nodejs-23.
|
|
14
|
+
if (!checkFileExists(path.join(__dirname, 'lib/groupdocs-conversion-nodejs-23.11.jar'))) {
|
|
15
|
+
console.warn('\x1b[33m%s\x1b[0m', `File groupdocs-conversion-nodejs-23.11.jar not found in the lib directory.\nPlease navigate to the package directory:`);
|
|
16
16
|
console.log('\n cd node_modules/@groupdocs/groupdocs.conversion\n');
|
|
17
17
|
console.warn('\x1b[33m%s\x1b[0m', `Then download the JAR file using the command:`);
|
|
18
18
|
console.log('\n npm run postinstall\n');
|
|
@@ -11,7 +11,7 @@ java.asyncOptions = {
|
|
|
11
11
|
syncSuffix: '',
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
java.classpath.push(path.join(__dirname, '/groupdocs-conversion-nodejs-23.
|
|
14
|
+
java.classpath.push(path.join(__dirname, '/groupdocs-conversion-nodejs-23.11.jar'))
|
|
15
15
|
|
|
16
16
|
exports = module.exports
|
|
17
17
|
|
|
@@ -26,14 +26,20 @@ function __typeof__(objClass) {
|
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
/** STREAM HELPERS * */
|
|
29
|
-
exports.readDataFromStream = function (readStream
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
29
|
+
exports.readDataFromStream = function (readStream) {
|
|
30
|
+
return new Promise((resolve, reject) => {
|
|
31
|
+
const inputStreamBuffer = new exports.StreamBuffer()
|
|
32
|
+
readStream.on('data', chunk => {
|
|
33
|
+
inputStreamBuffer.write(chunk)
|
|
34
|
+
})
|
|
35
|
+
readStream.on('end', () => {
|
|
36
|
+
try {
|
|
37
|
+
resolve(inputStreamBuffer.toInputStream())
|
|
38
|
+
} catch (err) {
|
|
39
|
+
reject(err);
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
});
|
|
37
43
|
}
|
|
38
44
|
|
|
39
45
|
exports.readBytesFromStream = function (readStream, callback) {
|
|
@@ -252,19 +258,3 @@ exports.StreamBuffer = class StreamBuffer {
|
|
|
252
258
|
}
|
|
253
259
|
}
|
|
254
260
|
|
|
255
|
-
/** STREAM METHODS * */
|
|
256
|
-
exports.License.setLicenseFromStream = function (license, licenseStream, callback) {
|
|
257
|
-
const inputStreamBuffer = new exports.StreamBuffer()
|
|
258
|
-
licenseStream.on('data', chunk => {
|
|
259
|
-
inputStreamBuffer.write(chunk)
|
|
260
|
-
})
|
|
261
|
-
licenseStream.on('end', () => {
|
|
262
|
-
let error
|
|
263
|
-
try {
|
|
264
|
-
license.setLicense(inputStreamBuffer.toInputStream())
|
|
265
|
-
} catch (err) {
|
|
266
|
-
error = err
|
|
267
|
-
}
|
|
268
|
-
callback(error)
|
|
269
|
-
})
|
|
270
|
-
}
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@groupdocs/groupdocs.conversion",
|
|
3
|
-
"version": "23.
|
|
3
|
+
"version": "23.11.0",
|
|
4
4
|
"description": "Powerful converter for PDF, Word, Excel, PowerPoint and image files.",
|
|
5
5
|
"scripts": {
|
|
6
|
-
"postinstall": "curl -H 'Cache-Control:no-cache' https://releases.groupdocs.com/java/repo/com/groupdocs/groupdocs-conversion-nodejs/23.
|
|
6
|
+
"postinstall": "curl -H 'Cache-Control:no-cache' https://releases.groupdocs.com/java/repo/com/groupdocs/groupdocs-conversion-nodejs/23.11/groupdocs-conversion-nodejs-23.11.jar > lib/groupdocs-conversion-nodejs-23.11.jar"
|
|
7
7
|
},
|
|
8
8
|
"main": "index.js",
|
|
9
9
|
"keywords": [
|