Document Gallery API: Difference between revisions

From Qt Wiki
Jump to navigation Jump to search
No edit summary
 
No edit summary
Line 1: Line 1:
'''English''' [[Document Gallery API|Spanish]]
'''English''' [[Document_Gallery_API|Spanish]]


=News=
[[Category:Developing with Qt::QtMobility]]<br />[toc align_right=&quot;yes&amp;quot; depth=&quot;3&amp;quot;]


[http://labs.qt.nokia.com/2011/05/04/qt-4-7-3-and-qt-mobility-1-1-3-have-been-released/ Qt Mobility 1.1.3 Release] ''[labs.qt.nokia.com]'' is available now for commercial app development and deployment on Ovi store.<br />[http://labs.qt.nokia.com/2011/05/12/qt-mobility-1-2-0-released/ Qt Mobility 1.2.0 release] ''[labs.qt.nokia.com]'' is available now.
= News =


=Document Gallery <span class="caps">API</span>=
&quot;Qt Mobility 1.1.3 Release&amp;quot;:http://labs.qt.nokia.com/2011/05/04/qt-4-7-3-and-qt-mobility-1-1-3-have-been-released/ is available now for commercial app development and deployment on Ovi store.<br />&quot;Qt Mobility 1.2.0 release&amp;quot;:http://labs.qt.nokia.com/2011/05/12/qt-mobility-1-2-0-released/ is available now.


==Summary==
= Document Gallery API =


A Document Gallery is a virtual gallery of documents and media. The [http://doc.qt.nokia.com/qtmobility-1.1.0/gallery.html Document Gallery <span class="caps">API</span>] ''[doc.qt.nokia.com]'' provides methods to discover the contents and their meta-data, of a Gallery.
== Summary ==
 
A Document Gallery is a virtual gallery of documents and media. The &quot;Document Gallery API&amp;quot;:http://doc.qt.nokia.com/qtmobility-1.1.0/gallery.html provides methods to discover the contents and their meta-data, of a Gallery.


Meta-data is information which describes a document, it can identify the creator of a document or a contributor, it can identify logical collections a document belongs to and significant dates in a documents history, and many other things. The document gallery stores all this information and provides interfaces to query it.
Meta-data is information which describes a document, it can identify the creator of a document or a contributor, it can identify logical collections a document belongs to and significant dates in a documents history, and many other things. The document gallery stores all this information and provides interfaces to query it.


Documents can be found in the gallery using their type, filters, and collections. The type of a document is a generic classification of its content and usually encapsulates multiple <span class="caps">MIME</span> types, a document may be a File, a Folder, a Document, Audio, an Image, Video, or a Playlist.
Documents can be found in the gallery using their type, filters, and collections. The type of a document is a generic classification of its content and usually encapsulates multiple MIME types, a document may be a File, a Folder, a Document, Audio, an Image, Video, or a Playlist.


Filters provide a means to express criteria which the meta-data of a document must pass for the document to be included in a query result. A filter either compares a meta-data property to a value or collects a group of sub-filters in a logical union or intersection.
Filters provide a means to express criteria which the meta-data of a document must pass for the document to be included in a query result. A filter either compares a meta-data property to a value or collects a group of sub-filters in a logical union or intersection.


Collections are sets of documents in the gallery that can all be identified by a common property or parent. Each collection is itself a document with its own set of properties that may be queried. Some collections mirror an actual file (Folder), while others are compiled from the meta-data documents they contain (Artist, Album Artist, Album, AudioGenre, PhotoAlbum).
Collections are sets of documents in the gallery that can all be identified by a common property or parent. Each collection is itself a document with its own set of properties that may be queried. Some collections mirror an actual file &amp;#40;Folder&amp;amp;#41;, while others are compiled from the meta-data documents they contain (Artist, Album Artist, Album, AudioGenre, PhotoAlbum).


==Key Features==
== Key Features ==


* Browse collections of documents with common identifying meta-data.
* Browse collections of documents with common identifying meta-data.
* Query meta-data values from individual documents and collections of documents.
* Query meta-data values from individual documents and collections of documents.  
* Edit the meta-data of documents.
* Edit the meta-data of documents.
* Filter query results using meta-data expressions.
* Filter query results using meta-data expressions.
Line 28: Line 30:
* Stay up to date as documents are added, removed, and changed with live queries.
* Stay up to date as documents are added, removed, and changed with live queries.


==Example applications==
== Example applications ==


===Media Browser===
=== Media Browser ===


The [http://doc.qt.nokia.com/qtmobility-1.1.0/mediabrowser.html Media Browser example] ''[doc.qt.nokia.com]'' demonstrates how to use collections to navigate the document gallery.
The &quot;Media Browser example&amp;quot;:http://doc.qt.nokia.com/qtmobility-1.1.0/mediabrowser.html demonstrates how to use collections to navigate the document gallery.


The application menu in the media browser provides a list of gallery item types; both collections (Artists, Album Artists and Albums) and documents (Songs and Photos). Selecting a type from the menu will display a list of all items of that type, and selecting a virtual item from that list will display items belonging to that collection.
The application menu in the media browser provides a list of gallery item types; both collections (Artists, Album Artists and Albums) and documents (Songs and Photos). Selecting a type from the menu will display a list of all items of that type, and selecting a virtual item from that list will display items belonging to that collection.
Line 38: Line 40:
The Media Browser also allows you to edit meta-data of items in the Songs list. Changing an editable field (Track number, Title, Artist, or Album Artist) will write those changes back to the gallery.
The Media Browser also allows you to edit meta-data of items in the Songs list. Changing an editable field (Track number, Title, Artist, or Album Artist) will write those changes back to the gallery.


===Document Share===
=== Document Share ===


The Document Share example is a simple web browser with a download manager which demonstrates how to query the meta-data of a document using it’s <span class="caps">URL</span>.
The Document Share example is a simple web browser with a download manager which demonstrates how to query the meta-data of a document using it's URL.


The download manager queries the document gallery for the ID and type of downloaded files, then when the user selects a file it is able to use that information to query the document gallery for type appropriate meta-data to present in a download summary.
The download manager queries the document gallery for the ID and type of downloaded files, then when the user selects a file it is able to use that information to query the document gallery for type appropriate meta-data to present in a download summary.
===Categories:===
* [[:Category:Developing with Qt|Developing_with_Qt]]
** [[:Category:Developing with Qt::QtMobility|QtMobility]]

Revision as of 11:08, 24 February 2015

English Spanish
[toc align_right="yes&quot; depth="3&quot;]

News

"Qt Mobility 1.1.3 Release&quot;:http://labs.qt.nokia.com/2011/05/04/qt-4-7-3-and-qt-mobility-1-1-3-have-been-released/ is available now for commercial app development and deployment on Ovi store.
"Qt Mobility 1.2.0 release&quot;:http://labs.qt.nokia.com/2011/05/12/qt-mobility-1-2-0-released/ is available now.

Document Gallery API

Summary

A Document Gallery is a virtual gallery of documents and media. The "Document Gallery API&quot;:http://doc.qt.nokia.com/qtmobility-1.1.0/gallery.html provides methods to discover the contents and their meta-data, of a Gallery.

Meta-data is information which describes a document, it can identify the creator of a document or a contributor, it can identify logical collections a document belongs to and significant dates in a documents history, and many other things. The document gallery stores all this information and provides interfaces to query it.

Documents can be found in the gallery using their type, filters, and collections. The type of a document is a generic classification of its content and usually encapsulates multiple MIME types, a document may be a File, a Folder, a Document, Audio, an Image, Video, or a Playlist.

Filters provide a means to express criteria which the meta-data of a document must pass for the document to be included in a query result. A filter either compares a meta-data property to a value or collects a group of sub-filters in a logical union or intersection.

Collections are sets of documents in the gallery that can all be identified by a common property or parent. Each collection is itself a document with its own set of properties that may be queried. Some collections mirror an actual file &#40;Folder&amp;#41;, while others are compiled from the meta-data documents they contain (Artist, Album Artist, Album, AudioGenre, PhotoAlbum).

Key Features

  • Browse collections of documents with common identifying meta-data.
  • Query meta-data values from individual documents and collections of documents.
  • Edit the meta-data of documents.
  • Filter query results using meta-data expressions.
  • Sort query results using meta-data.
  • Stay up to date as documents are added, removed, and changed with live queries.

Example applications

Media Browser

The "Media Browser example&quot;:http://doc.qt.nokia.com/qtmobility-1.1.0/mediabrowser.html demonstrates how to use collections to navigate the document gallery.

The application menu in the media browser provides a list of gallery item types; both collections (Artists, Album Artists and Albums) and documents (Songs and Photos). Selecting a type from the menu will display a list of all items of that type, and selecting a virtual item from that list will display items belonging to that collection.

The Media Browser also allows you to edit meta-data of items in the Songs list. Changing an editable field (Track number, Title, Artist, or Album Artist) will write those changes back to the gallery.

Document Share

The Document Share example is a simple web browser with a download manager which demonstrates how to query the meta-data of a document using it's URL.

The download manager queries the document gallery for the ID and type of downloaded files, then when the user selects a file it is able to use that information to query the document gallery for type appropriate meta-data to present in a download summary.