Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
androidcontentfileengine.cpp File Reference

(f735cf7cd174c98606a03349507e3bb18589e417)

#include "androidcontentfileengine.h"
#include <QtCore/qcoreapplication.h>
#include <QtCore/qjnienvironment.h>
#include <QtCore/qjniobject.h>
#include <QtCore/qurl.h>
#include <QtCore/qdatetime.h>
#include <QtCore/qmimedatabase.h>
#include <QtCore/qdebug.h>
#include <QtCore/qloggingcategory.h>
Include dependency graph for androidcontentfileengine.cpp:

Go to the source code of this file.

Classes

class  Cursor

Namespaces

namespace  DocumentsContract
 DocumentsContract Api.
namespace  DocumentsContract::Document

Functions

 Q_DECLARE_JNI_CLASS (ParcelFileDescriptorType, "android/os/ParcelFileDescriptor")
 Q_DECLARE_JNI_CLASS (CursorType, "android/database/Cursor")
 Q_DECLARE_JNI_CLASS (QtContentFileEngine, "org/qtproject/qt/android/QtContentFileEngine")
 Q_DECLARE_JNI_CLASS (List, "java/util/List")
static QJniObjectcontentResolverInstance ()
 Q_DECLARE_JNI_CLASS (DocumentsContract, "android/provider/DocumentsContract")
QString DocumentsContract::documentId (const QJniObject &uri)
QString DocumentsContract::treeDocumentId (const QJniObject &uri)
QJniObject DocumentsContract::buildChildDocumentsUriUsingTree (const QJniObject &uri, const QString &parentDocumentId)
QJniObject DocumentsContract::buildDocumentUriUsingTree (const QJniObject &treeUri, const QString &documentId)
bool DocumentsContract::isDocumentUri (const QJniObject &uri)
bool DocumentsContract::isTreeUri (const QJniObject &uri)
QJniObject DocumentsContract::createDocument (const QJniObject &parentDocumentUri, const QString &mimeType, const QString &displayName)
bool DocumentsContract::deleteDocument (const QJniObject &documentUri)
QJniObject DocumentsContract::moveDocument (const QJniObject &sourceDocumentUri, const QJniObject &sourceParentDocumentUri, const QJniObject &targetParentDocumentUri)
QJniObject DocumentsContract::renameDocument (const QJniObject &documentUri, const QString &displayName)
QJniObject parseUri (const QString &uri)

Variables

constexpr char contentScheme [] = "content"
constexpr char contentSchemeFull [] = "content://"
constexpr char treeSegment [] = "tree"
constexpr char documentSegment [] = "document"
constexpr char childrenSegment [] = "%2Fchildren"
const QLatin1String DocumentsContract::Document::COLUMN_DISPLAY_NAME ("_display_name")
const QLatin1String DocumentsContract::Document::COLUMN_DOCUMENT_ID ("document_id")
const QLatin1String DocumentsContract::Document::COLUMN_FLAGS ("flags")
const QLatin1String DocumentsContract::Document::COLUMN_LAST_MODIFIED ("last_modified")
const QLatin1String DocumentsContract::Document::COLUMN_MIME_TYPE ("mime_type")
const QLatin1String DocumentsContract::Document::COLUMN_SIZE ("_size")
constexpr int DocumentsContract::Document::FLAG_DIR_SUPPORTS_CREATE = 0x00000008
constexpr int DocumentsContract::Document::FLAG_SUPPORTS_DELETE = 0x00000004
constexpr int DocumentsContract::Document::FLAG_SUPPORTS_MOVE = 0x00000100
constexpr int DocumentsContract::Document::FLAG_SUPPORTS_RENAME = 0x00000040
constexpr int DocumentsContract::Document::FLAG_SUPPORTS_WRITE = 0x00000002
constexpr int DocumentsContract::Document::FLAG_VIRTUAL_DOCUMENT = 0x00000200
const QLatin1String DocumentsContract::Document::MIME_TYPE_DIR ("vnd.android.document/directory")

Function Documentation

◆ contentResolverInstance()

QJniObject & contentResolverInstance ( )
static

Definition at line 35 of file androidcontentfileengine.cpp.

◆ parseUri()

QJniObject parseUri ( const QString & uri)

Definition at line 635 of file androidcontentfileengine.cpp.

◆ Q_DECLARE_JNI_CLASS() [1/5]

Q_DECLARE_JNI_CLASS ( CursorType ,
"android/database/Cursor"  )

◆ Q_DECLARE_JNI_CLASS() [2/5]

Q_DECLARE_JNI_CLASS ( DocumentsContract ,
"android/provider/DocumentsContract"  )

◆ Q_DECLARE_JNI_CLASS() [3/5]

Q_DECLARE_JNI_CLASS ( List ,
"java/util/List"  )

◆ Q_DECLARE_JNI_CLASS() [4/5]

Q_DECLARE_JNI_CLASS ( ParcelFileDescriptorType ,
"android/os/ParcelFileDescriptor"  )

◆ Q_DECLARE_JNI_CLASS() [5/5]

Q_DECLARE_JNI_CLASS ( QtContentFileEngine ,
"org/qtproject/qt/android/QtContentFileEngine"  )

Variable Documentation

◆ childrenSegment

char childrenSegment = "%2Fchildren"
constexpr

Definition at line 33 of file androidcontentfileengine.cpp.

◆ contentScheme

char contentScheme = "content"
constexpr

Definition at line 29 of file androidcontentfileengine.cpp.

◆ contentSchemeFull

char contentSchemeFull = "content://"
constexpr

Definition at line 30 of file androidcontentfileengine.cpp.

Referenced by DocumentFile::rename().

◆ documentSegment

char documentSegment = "document"
constexpr

Definition at line 32 of file androidcontentfileengine.cpp.

Referenced by DocumentFile::parseFromAnyUri().

◆ treeSegment

char treeSegment = "tree"
constexpr

Definition at line 31 of file androidcontentfileengine.cpp.

Referenced by DocumentFile::parseFromAnyUri().