io.qt.activex.QAxScriptEngine Maven / Gradle / Ivy
package io.qt.activex;
import io.qt.*;
/**
* Wrapper around a script engine
* Java wrapper for Qt class QAxScriptEngine
*/
public class QAxScriptEngine extends io.qt.activex.QAxObject
{
/**
* Java wrapper for Qt enum QAxScriptEngine::State
*/
@QtUnlistedEnum
public enum State implements QtEnumerator {
/**
* Representing QAxScriptEngine:: Uninitialized
*/
Uninitialized(0),
/**
* Representing QAxScriptEngine:: Initialized
*/
Initialized(5),
/**
* Representing QAxScriptEngine:: Started
*/
Started(1),
/**
* Representing QAxScriptEngine:: Connected
*/
Connected(2),
/**
* Representing QAxScriptEngine:: Disconnected
*/
Disconnected(3),
/**
* Representing QAxScriptEngine:: Closed
*/
Closed(4);
static {
QtJambi_LibraryUtilities.initialize();
}
private State(int value) {
this.value = value;
}
/**
* {@inheritDoc}
*/
@Override
public int value() {
return value;
}
/**
* Returns the corresponding enum entry for the given value.
* @param value
* @return enum entry
*/
public static @NonNull State resolve(int value) {
switch (value) {
case 0: return Uninitialized;
case 5: return Initialized;
case 1: return Started;
case 2: return Connected;
case 3: return Disconnected;
case 4: return Closed;
default: throw new QNoSuchEnumValueException(value);
}
}
private final int value;
}
/**
* See QAxScriptEngine:: QAxScriptEngine(QString, QAxScript*)
* @param language
* @param script
*/
public QAxScriptEngine(java.lang.@NonNull String language, io.qt.activex.@Nullable QAxScript script){
super((QPrivateConstructor)null);
initialize_native(this, language, script);
}
private native static void initialize_native(QAxScriptEngine instance, java.lang.String language, io.qt.activex.QAxScript script);
/**
* See QAxScriptEngine:: addItem(QString)
* @param name
*/
@QtUninvokable
public final void addItem(java.lang.@NonNull String name){
addItem_native_cref_QString(QtJambi_LibraryUtilities.internal.nativeId(this), name);
}
@QtUninvokable
private native void addItem_native_cref_QString(long __this__nativeId, java.lang.String name);
/**
* See QAxScriptEngine:: hasIntrospection()const
* @return
*/
@QtUninvokable
public final boolean hasIntrospection(){
return hasIntrospection_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native boolean hasIntrospection_native_constfct(long __this__nativeId);
/**
* See QAxScriptEngine:: isValid()const
* @return
*/
@QtUninvokable
public final boolean isValid(){
return isValid_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native boolean isValid_native_constfct(long __this__nativeId);
/**
* See QAxScriptEngine:: scriptLanguage()const
* @return
*/
@QtUninvokable
public final java.lang.@NonNull String scriptLanguage(){
return scriptLanguage_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this));
}
@QtUninvokable
private native java.lang.String scriptLanguage_native_constfct(long __this__nativeId);
/**
* See QAxScriptEngine:: setState(QAxScriptEngine::State)
* @param st
*/
@QtUninvokable
public final void setState(io.qt.activex.QAxScriptEngine.@NonNull State st){
setState_native_QAxScriptEngine_State(QtJambi_LibraryUtilities.internal.nativeId(this), st.value());
}
@QtUninvokable
private native void setState_native_QAxScriptEngine_State(long __this__nativeId, int st);
/**
* See QAxScriptEngine:: state()const
* @return
*/
@QtUninvokable
public final io.qt.activex.QAxScriptEngine.@NonNull State state(){
return io.qt.activex.QAxScriptEngine.State.resolve(state_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)));
}
@QtUninvokable
private native int state_native_constfct(long __this__nativeId);
/**
* Constructor for internal use only.
* @param p expected to be null
.
* @hidden
*/
@NativeAccess
protected QAxScriptEngine(QPrivateConstructor p) { super(p); }
}