All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.qt.bluetooth.QBluetoothServer Maven / Gradle / Ivy

package io.qt.bluetooth;

import io.qt.*;


/**
 * 

Uses the RFCOMM or L2cap protocol to communicate with a Bluetooth device

*

Java wrapper for Qt class QBluetoothServer

*/ public class QBluetoothServer extends io.qt.core.QObject { static { QtJambi_LibraryUtilities.initialize(); } /** * This variable stores the meta-object for the class. */ public static final io.qt.core.@NonNull QMetaObject staticMetaObject = io.qt.core.QMetaObject.forType(QBluetoothServer.class); /** *

Java wrapper for Qt enum QBluetoothServer::Error

*/ public enum Error implements QtEnumerator { /** *

Representing QBluetoothServer::NoError

*/ NoError(0), /** *

Representing QBluetoothServer::UnknownError

*/ UnknownError(1), /** *

Representing QBluetoothServer::PoweredOffError

*/ PoweredOffError(2), /** *

Representing QBluetoothServer::InputOutputError

*/ InputOutputError(3), /** *

Representing QBluetoothServer::ServiceAlreadyRegisteredError

*/ ServiceAlreadyRegisteredError(4), /** *

Representing QBluetoothServer::UnsupportedProtocolError

*/ UnsupportedProtocolError(5); static { QtJambi_LibraryUtilities.initialize(); } private Error(int value) { this.value = value; } /** * {@inheritDoc} */ public int value() { return value; } /** * Returns the corresponding enum entry for the given value. * @param value * @return enum entry */ public static @NonNull Error resolve(int value) { switch (value) { case 0: return NoError; case 1: return UnknownError; case 2: return PoweredOffError; case 3: return InputOutputError; case 4: return ServiceAlreadyRegisteredError; case 5: return UnsupportedProtocolError; default: throw new QNoSuchEnumValueException(value); } } private final int value; } /** *

See QBluetoothServer::error(QBluetoothServer::Error)

*/ public final @NonNull Signal1 error = new Signal1<>(); /** *

See QBluetoothServer::newConnection()

*/ public final @NonNull Signal0 newConnection = new Signal0(); /** *

See QBluetoothServer::QBluetoothServer(QBluetoothServiceInfo::Protocol,QObject*)

*/ public QBluetoothServer(io.qt.bluetooth.QBluetoothServiceInfo.@NonNull Protocol serverType, io.qt.core.@Nullable QObject parent){ super((QPrivateConstructor)null); initialize_native(this, serverType, parent); } private native static void initialize_native(QBluetoothServer instance, io.qt.bluetooth.QBluetoothServiceInfo.Protocol serverType, io.qt.core.QObject parent); /** *

See QBluetoothServer::close()

*/ @QtUninvokable public final void close(){ close_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native void close_native(long __this__nativeId); /** *

See QBluetoothServer::error()const

*/ @QtUninvokable public final io.qt.bluetooth.QBluetoothServer.@NonNull Error error(){ return io.qt.bluetooth.QBluetoothServer.Error.resolve(error_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int error_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::hasPendingConnections()const

*/ @QtUninvokable public final boolean hasPendingConnections(){ return hasPendingConnections_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean hasPendingConnections_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::isListening()const

*/ @QtUninvokable public final boolean isListening(){ return isListening_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native boolean isListening_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::listen(QBluetoothAddress,quint16)

*/ @QtUninvokable public final boolean listen(io.qt.bluetooth.@NonNull QBluetoothAddress address, short port){ return listen_native_cref_QBluetoothAddress_quint16(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(address), port); } @QtUninvokable private native boolean listen_native_cref_QBluetoothAddress_quint16(long __this__nativeId, long address, short port); /** *

See QBluetoothServer::listen(QBluetoothUuid,QString)

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.@NonNull QBluetoothUuid uuid, java.lang.@NonNull String serviceName){ return listen_native_cref_QBluetoothUuid_cref_QString(QtJambi_LibraryUtilities.internal.nativeId(this), QtJambi_LibraryUtilities.internal.checkedNativeId(uuid), serviceName); } @QtUninvokable private native io.qt.bluetooth.QBluetoothServiceInfo listen_native_cref_QBluetoothUuid_cref_QString(long __this__nativeId, long uuid, java.lang.String serviceName); /** *

See QBluetoothServer::maxPendingConnections()const

*/ @QtUninvokable public final int maxPendingConnections(){ return maxPendingConnections_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native int maxPendingConnections_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::nextPendingConnection()

*/ @QtUninvokable public final io.qt.bluetooth.@Nullable QBluetoothSocket nextPendingConnection(){ return nextPendingConnection_native(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.bluetooth.QBluetoothSocket nextPendingConnection_native(long __this__nativeId); /** *

See QBluetoothServer::securityFlags()const

*/ @QtUninvokable public final io.qt.bluetooth.QBluetooth.@NonNull SecurityFlags securityFlags(){ return new io.qt.bluetooth.QBluetooth.SecurityFlags(securityFlags_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int securityFlags_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::serverAddress()const

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothAddress serverAddress(){ return serverAddress_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native io.qt.bluetooth.QBluetoothAddress serverAddress_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::serverPort()const

*/ @QtUninvokable public final short serverPort(){ return serverPort_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this)); } @QtUninvokable private native short serverPort_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::serverType()const

*/ @QtUninvokable public final io.qt.bluetooth.QBluetoothServiceInfo.@NonNull Protocol serverType(){ return io.qt.bluetooth.QBluetoothServiceInfo.Protocol.resolve(serverType_native_constfct(QtJambi_LibraryUtilities.internal.nativeId(this))); } @QtUninvokable private native int serverType_native_constfct(long __this__nativeId); /** *

See QBluetoothServer::setMaxPendingConnections(int)

*/ @QtUninvokable public final void setMaxPendingConnections(int numConnections){ setMaxPendingConnections_native_int(QtJambi_LibraryUtilities.internal.nativeId(this), numConnections); } @QtUninvokable private native void setMaxPendingConnections_native_int(long __this__nativeId, int numConnections); /** *

See QBluetoothServer::setSecurityFlags(QBluetooth::SecurityFlags)

*/ @QtUninvokable public final void setSecurityFlags(io.qt.bluetooth.QBluetooth.@NonNull SecurityFlags security){ setSecurityFlags_native_QBluetooth_SecurityFlags(QtJambi_LibraryUtilities.internal.nativeId(this), security.value()); } @QtUninvokable private native void setSecurityFlags_native_QBluetooth_SecurityFlags(long __this__nativeId, int security); /** * Constructor for internal use only. * @param p expected to be null. * @hidden */ @NativeAccess protected QBluetoothServer(QPrivateConstructor p) { super(p); } /** *

Overloaded constructor for {@link #QBluetoothServer(io.qt.bluetooth.QBluetoothServiceInfo.Protocol, io.qt.core.QObject)} * with parent = null.

*/ public QBluetoothServer(io.qt.bluetooth.QBluetoothServiceInfo.@NonNull Protocol serverType) { this(serverType, (io.qt.core.QObject)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothAddress, short)} * with port = 0.

*/ @QtUninvokable public final boolean listen(io.qt.bluetooth.@NonNull QBluetoothAddress address) { return listen(address, (short)0); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothAddress, short)}

*

with:

    *
  • address = new io.qt.bluetooth.QBluetoothAddress()
  • *
  • port = 0
  • *
*/ @QtUninvokable public final boolean listen() { return listen(new io.qt.bluetooth.QBluetoothAddress(), (short)0); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid, java.lang.String)} * with serviceName = (String)null.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.@NonNull QBluetoothUuid uuid) { return listen(uuid, (String)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid.ProtocolUuid, java.lang.String)} * with serviceName = (String)null.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull ProtocolUuid uuid) { return listen(uuid, (String)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid, java.lang.String)}.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull ProtocolUuid uuid, java.lang.@NonNull String serviceName) { return listen(new io.qt.bluetooth.QBluetoothUuid(uuid), serviceName); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid.ServiceClassUuid, java.lang.String)} * with serviceName = (String)null.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull ServiceClassUuid uuid) { return listen(uuid, (String)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid, java.lang.String)}.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull ServiceClassUuid uuid, java.lang.@NonNull String serviceName) { return listen(new io.qt.bluetooth.QBluetoothUuid(uuid), serviceName); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid.CharacteristicType, java.lang.String)} * with serviceName = (String)null.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull CharacteristicType uuid) { return listen(uuid, (String)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid, java.lang.String)}.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull CharacteristicType uuid, java.lang.@NonNull String serviceName) { return listen(new io.qt.bluetooth.QBluetoothUuid(uuid), serviceName); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid.DescriptorType, java.lang.String)} * with serviceName = (String)null.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull DescriptorType uuid) { return listen(uuid, (String)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid, java.lang.String)}.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.bluetooth.QBluetoothUuid.@NonNull DescriptorType uuid, java.lang.@NonNull String serviceName) { return listen(new io.qt.bluetooth.QBluetoothUuid(uuid), serviceName); } /** *

Overloaded function for {@link #listen(io.qt.core.QUuid, java.lang.String)} * with serviceName = (String)null.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.core.@NonNull QUuid uuid) { return listen(uuid, (String)null); } /** *

Overloaded function for {@link #listen(io.qt.bluetooth.QBluetoothUuid, java.lang.String)}.

*/ @QtUninvokable public final io.qt.bluetooth.@NonNull QBluetoothServiceInfo listen(io.qt.core.@NonNull QUuid uuid, java.lang.@NonNull String serviceName) { return listen(new io.qt.bluetooth.QBluetoothUuid(uuid), serviceName); } /** *

Overloaded function for {@link #setSecurityFlags(io.qt.bluetooth.QBluetooth.SecurityFlags)}.

*/ @QtUninvokable public final void setSecurityFlags(io.qt.bluetooth.QBluetooth.@NonNull Security @NonNull... security) { setSecurityFlags(new io.qt.bluetooth.QBluetooth.SecurityFlags(security)); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy