blob: e955e76ec5e0aeaf187fbd9505a019ec2265e95d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
#pragma once
#include <jni.h>
#include "settings.h"
/*
This class stores data about a Ghostscript instance.
*/
class GSInstanceData
{
public:
void *instance = NULL; // The Ghostscript instance
void *callerHandle = NULL; // The caller handle passed to gsapi_new_instance
void *stdioHandle = NULL; // The caller handle passed to gsapi_set_stdio_with_handle
JNIEnv *env; // The JNIEnv which should be used for JNI API calls
jobject stdIn = NULL; // The user IStdInFunction class for stdin input
jobject stdOut = NULL; // The user IStdOutFunction class for stdout output
jobject stdErr = NULL; // The user IStdErrFunction class for stderr output
jobject poll = NULL; // The user IPollFunction class
jobject displayCallback = NULL; // The user DisplayCallback class
jobject callout = NULL; // The user ICalloutFunction class
};
GSInstanceData *putInstanceData(GSInstanceData *data);
GSInstanceData *findDataFromInstance(void *instance);
void deleteDataFromInstance(void *instance);
|