java.lang.Object
io.qt.core.QScopedPointer<O>
- All Implemented Interfaces:
AutoCloseable
Java wrapper for Qt class QScopedPointer to be used inside a try-with-resource block.
Example:
try(var pointer = QScopedPointer.disposing(new QDialog())){
QDialog dialog = pointer.get();
dialog.exec();
}
// dialog is disposed
-
Method Summary
Modifier and TypeMethodDescriptionstatic <O> QScopedPointer<O>
void
close()
data()
static <O extends QtObjectInterface>
QScopedPointer<O>disposing
(O data) static <O extends QObject>
QScopedPointer<O>disposingLater
(O data) get()
boolean
isNull()
void
void
swap
(QScopedPointer<O> other) take()
-
Method Details
-
data
-
get
-
take
-
reset
-
isNull
-
swap
-
close
- Specified by:
close
in interfaceAutoCloseable
-
disposing
-
disposingLater
-
cleanup
-