java.lang.Object
io.qt.QtUtilities
This class contains static members that gives information and performs QtJambi related tasks.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceEquivalent toIntSupplierwithbyteresult.static interfaceEquivalent toIntSupplierwithcharresult.static interfaceEquivalent toConsumerwith ten arguments.static interfaceEquivalent toConsumerwith three arguments.static interfaceEquivalent toConsumerwith four arguments.static interfaceEquivalent toConsumerwith five arguments.static interfaceEquivalent toConsumerwith six arguments.static interfaceEquivalent toConsumerwith seven arguments.static interfaceEquivalent toConsumerwith eight arguments.static interfaceEquivalent toConsumerwith nine arguments.static interfaceEquivalent toDoubleSupplierwithfloatresult.static enumEnum for requirement.static interfaceEquivalent toIntSupplierwithshortresult.static interfaceEquivalent toSupplier. -
Method Summary
Modifier and TypeMethodDescriptionstatic QObjectasSelectiveEventFilter(QObject eventFilter, QEvent.Type eventType, QEvent.Type ... eventTypes) Reduces the number of native-to-java conversions by pre-filtering the events according to the given event types.static StringThis function gets the value of the environment variable named varName.static QMetaObject.DisposedSignalgetSignalOnDispose(QtObjectInterface object) static voidstatic voidinitializeNativeObject(QtObjectInterface object, QtArgument.Stream arguments) static booleaninitializePackage(String packagePath) static booleaninitializePackage(Class<?> cls) static booleaninitializePackage(Package pkg) static booleanisAvailableQtLibrary(String library) static booleanisAvailableUtilityLibrary(String library) static booleanisAvailableUtilityLibrary(String library, String versionString) static Filestatic FileDeprecated, for removal: This API element is subject to removal in a future version.static voidloadJambiLibrary(String library) static voidloadLibrary(String lib) static voidloadQtJambiLibrary(String library) static voidloadQtLibrary(String library) static voidloadQtLibrary(String library, QtUtilities.LibraryRequirementMode mode, String ... platforms) static voidloadUtilityLibrary(String library) static voidloadUtilityLibrary(String library, QtUtilities.LibraryRequirementMode mode, String ... platforms) static voidloadUtilityLibrary(String library, String version) static voidloadUtilityLibrary(String library, String version, QtUtilities.LibraryRequirementMode mode, String ... platforms) static booleanThis function sets the value of the environment variable named varName.static QVersionNumberReturn the version of QtJambistatic booleanThis method allows to reinstall the QtJambi event notify callback as the last callback.static booleanThird-party libraries must not overwrite Java's installed signal handlers.static booleanThird-party libraries must not overwrite Java's installed signal handlers.static voidthreadCheck(QObject object) Checks if the current thread is the given object's thread and throws QThreadAffinityException otherwise.static voidChecks if the current thread is UI thread and throws QThreadAffinityException otherwise.static booleanThis function deletes the variable varName from the environment.static voiduseAsGadget(Class<?> clazz) Use a class (e.g.static voidusePackageContentAsGadgets(String _package) Define a package (e.g.
-
Method Details
-
isAvailableQtLibrary
-
isAvailableUtilityLibrary
-
isAvailableUtilityLibrary
-
loadQtLibrary
-
loadQtLibrary
public static void loadQtLibrary(String library, QtUtilities.LibraryRequirementMode mode, String ... platforms) -
loadUtilityLibrary
-
loadUtilityLibrary
public static void loadUtilityLibrary(String library, QtUtilities.LibraryRequirementMode mode, String ... platforms) -
loadUtilityLibrary
-
loadUtilityLibrary
public static void loadUtilityLibrary(String library, String version, QtUtilities.LibraryRequirementMode mode, String ... platforms) -
loadQtJambiLibrary
-
loadJambiLibrary
-
loadLibrary
-
useAsGadget
Use a class (e.g. from third party library) as gadget.- See Also:
-
usePackageContentAsGadgets
Define a package (e.g. from third party library) to let all its classes considered to be gadgets.- See Also:
-
jambiDeploymentDir
-
jambiTempDir
Deprecated, for removal: This API element is subject to removal in a future version.UsejambiDeploymentDir()instead.- Returns:
-
initializePackage
-
initializePackage
-
initializePackage
-
getSignalOnDispose
-
initializeNativeObject
-
initializeNativeObject
-
putenv
This function sets the value of the environment variable named varName.- Parameters:
varName-value-
-
unsetenv
This function deletes the variable varName from the environment.- Parameters:
varName-
-
getenv
This function gets the value of the environment variable named varName.- Parameters:
varName-- Returns:
- value
-
reinstallEventNotifyCallback
public static boolean reinstallEventNotifyCallback()This method allows to reinstall the QtJambi event notify callback as the last callback. If other libraries register their event notify callback to Qt, it is necessary to make sure QtJambi's callback is called at last. This method can only be called from inside the main thread and before callingQCoreApplication.exec(). -
saveUnixSignalHandlers
public static boolean saveUnixSignalHandlers()Third-party libraries must not overwrite Java's installed signal handlers. Several of these signal handlers are crucial for JVM to work. This method saves the installed signal handlers for later restoring byrestoreUnixSignalHandlers(). -
restoreUnixSignalHandlers
public static boolean restoreUnixSignalHandlers()Third-party libraries must not overwrite Java's installed signal handlers. Several of these signal handlers are crucial for JVM to work. This method restores the signal handlers previously saved bysaveUnixSignalHandlers(). -
qtjambiVersion
Return the version of QtJambi- Returns:
- qtjambi version
-
uiThreadCheck
Checks if the current thread is UI thread and throws QThreadAffinityException otherwise.- Throws:
QThreadAffinityException
-
threadCheck
Checks if the current thread is the given object's thread and throws QThreadAffinityException otherwise.- Throws:
QThreadAffinityException
-
asSelectiveEventFilter
public static QObject asSelectiveEventFilter(QObject eventFilter, QEvent.Type eventType, QEvent.Type ... eventTypes) Reduces the number of native-to-java conversions by pre-filtering the events according to the given event types.- Parameters:
eventFilter-eventType-eventTypes-- Returns:
- selective event filter
-
jambiDeploymentDir()instead.