<?xml version="1.0" encoding="ANSI_X3.4-1968" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968" /><title>org.freedesktop.Secret.Collection</title><link rel="stylesheet" href="style.css" type="text/css" /><meta name="generator" content="DocBook XSL Stylesheets V1.75.2" /><link rel="home" href="index.html" title="Secrets Service API Draft" /><link rel="up" href="ch13.html" title="Chapter&#160;13.&#160;Interfaces" /><link rel="prev" href="re01.html" title="org.freedesktop.Secret.Service" /><link rel="next" href="re03.html" title="org.freedesktop.Secret.Item" /></head><body><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">
          <code class="literal">org.freedesktop.Secret.Collection</code>
        </th></tr><tr><td width="20%" align="left"><a accesskey="p" href="re01.html">Prev</a>&#160;</td><th width="60%" align="center">Chapter&#160;13.&#160;Interfaces</th><td width="20%" align="right">&#160;<a accesskey="n" href="re03.html">Next</a></td></tr></table><hr /></div><div class="refentry" title="org.freedesktop.Secret.Collection"><a id="org.freedesktop.Secret.Collection"></a><div class="titlepage"></div><div class="refnamediv"><h2><span class="refentrytitle">
          <code class="literal">org.freedesktop.Secret.Collection</code>
        </span></h2><p>org.freedesktop.Secret.Collection &#8212; A collection of items containing secrets.</p></div><div class="refsynopsisdiv" title="Synopsis"><h2>Synopsis</h2><div class="refsect2" title="Methods"><a id="id1229380"></a><h3>Methods</h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">Delete</b>
              (</code></td><td>OUT ObjectPath <var class="pdparam">prompt</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">SearchItems</b>
              (</code></td><td>IN Dict&lt;String,String&gt; <var class="pdparam">attributes</var>, </td></tr><tr><td>&#160;</td><td>OUT Array&lt;ObjectPath&gt; <var class="pdparam">results</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">CreateItem</b>
              (</code></td><td>IN Dict&lt;String,Variant&gt; <var class="pdparam">properties</var>, </td></tr><tr><td>&#160;</td><td>IN Secret <var class="pdparam">secret</var>, </td></tr><tr><td>&#160;</td><td>IN Boolean <var class="pdparam">replace</var>, </td></tr><tr><td>&#160;</td><td>OUT ObjectPath <var class="pdparam">item</var>, </td></tr><tr><td>&#160;</td><td>OUT ObjectPath <var class="pdparam">prompt</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div></div><div class="refsect2" title="Signals"><a id="id1229498"></a><h3>Signals</h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">ItemCreated</b>
              (</code></td><td>IN ObjectPath <var class="pdparam">item</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">ItemDeleted</b>
              (</code></td><td>IN ObjectPath <var class="pdparam">item</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">ItemChanged</b>
              (</code></td><td>IN ObjectPath <var class="pdparam">item</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div></div><div class="refsect2" title="Properties"><a id="id1229563"></a><h3>Properties</h3><div class="refsynopsisdiv"><h2></h2><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">Array&lt;ObjectPath&gt;&#160;</span><span class="varname">Items&#160;</span>;</code><br /><code class="fieldsynopsis"><span class="modifier">READWRITE&#160;</span><span class="type">String&#160;</span><span class="varname">Label&#160;</span>;</code><br /><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">Boolean&#160;</span><span class="varname">Locked&#160;</span>;</code><br /><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">UInt64&#160;</span><span class="varname">Created&#160;</span>;</code><br /><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">UInt64&#160;</span><span class="varname">Modified&#160;</span>;</code></div></div></div><div class="refsection" title="Methods"><a id="id1229634"></a><h2>Methods</h2><div class="refsection" title="org.freedesktop.Secret.Collection.Delete"><a id="org.freedesktop.Secret.Collection.Delete"></a><h3>
            <code class="literal">org.freedesktop.Secret.Collection.Delete</code>
          </h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">Delete</b>
              (</code></td><td>OUT ObjectPath <var class="pdparam">prompt</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div><p>Delete this collection.</p><div class="glosslist"><dl><dt>
                <code class="literal">prompt</code>
              </dt><dd><p>A prompt to delete the collection, or the special value '/' when no prompt is necessary.</p></dd></dl></div></div><div class="refsection" title="org.freedesktop.Secret.Collection.SearchItems"><a id="org.freedesktop.Secret.Collection.SearchItems"></a><h3>
            <code class="literal">org.freedesktop.Secret.Collection.SearchItems</code>
          </h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">SearchItems</b>
              (</code></td><td>IN Dict&lt;String,String&gt; <var class="pdparam">attributes</var>, </td></tr><tr><td>&#160;</td><td>OUT Array&lt;ObjectPath&gt; <var class="pdparam">results</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div><p>Search for items in this collection matching the lookup attributes.</p><div class="glosslist"><dl><dt>
                <code class="literal">attributes</code>
              </dt><dd><p>Attributes to match.</p></dd><dt>
                <code class="literal">results</code>
              </dt><dd><p>Items that matched the attributes.</p></dd></dl></div></div><div class="refsection" title="org.freedesktop.Secret.Collection.CreateItem"><a id="org.freedesktop.Secret.Collection.CreateItem"></a><h3>
            <code class="literal">org.freedesktop.Secret.Collection.CreateItem</code>
          </h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">CreateItem</b>
              (</code></td><td>IN Dict&lt;String,Variant&gt; <var class="pdparam">properties</var>, </td></tr><tr><td>&#160;</td><td>IN Secret <var class="pdparam">secret</var>, </td></tr><tr><td>&#160;</td><td>IN Boolean <var class="pdparam">replace</var>, </td></tr><tr><td>&#160;</td><td>OUT ObjectPath <var class="pdparam">item</var>, </td></tr><tr><td>&#160;</td><td>OUT ObjectPath <var class="pdparam">prompt</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div><p>Create an item with the given attributes, secret and label. If replace is set, then it replaces an item already present with the same values for the attributes.</p><div class="glosslist"><dl><dt>
                <code class="literal">properties</code>
              </dt><dd><p>The properties for the new item.
                        </p><p>
                            Properties for the new item. This allows setting the new item's
                            properties upon its creation. All READWRITE properties are useable.
                            Specify the property names in full interface.Property form.
                            </p><div class="example"><a id="id1229844"></a><p class="title"><b>Example&#160;13.2.&#160;Example for properties</b></p><div class="example-contents"><pre class="programlisting">

properties = {
               "org.freedesktop.Secret.Item.Label": "MyItem",
               "org.freedesktop.Secret.Item.Attributes": {
                          "Attribute1": "Value1",
                          "Attribute2": "Value2"
                    }
             }

                                </pre></div></div><p><br class="example-break" />
                            </p><div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Note</h3><p>
                                    Please note that there is a distinction between the terms
                                    <span class="emphasis"><em>Property</em></span>, which refers to a D-Bus properties
                                    of an object, and <span class="emphasis"><em>Attribute</em></span>, which refers to one
                                    of a secret item's string-valued attributes.
                                </p></div><p>
                        </p><p>
                    </p></dd><dt>
                <code class="literal">secret</code>
              </dt><dd><p>The secret to store in the item, encoded with the included session.</p></dd><dt>
                <code class="literal">replace</code>
              </dt><dd><p>Whether to replace an item with the same attributes or not.</p></dd><dt>
                <code class="literal">item</code>
              </dt><dd><p>The item created, or the special value '/' if a prompt is necessary.</p></dd><dt>
                <code class="literal">prompt</code>
              </dt><dd><p>A prompt object, or the special value '/' if no prompt is necessary.</p></dd></dl></div></div></div><div class="refsection" title="Signals"><a id="id1229922"></a><h2>Signals</h2><div class="refsection" title="org.freedesktop.Secret.Collection.ItemCreated"><a id="org.freedesktop.Secret.Collection.ItemCreated"></a><h3>
            <code class="literal">org.freedesktop.Secret.Collection.ItemCreated</code>
          </h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">ItemCreated</b>
              (</code></td><td>IN ObjectPath <var class="pdparam">item</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div><p>A new item in this collection was created.</p><div class="glosslist"><dl><dt>
                <code class="literal">item</code>
              </dt><dd><p>The item that was created.</p></dd></dl></div></div><div class="refsection" title="org.freedesktop.Secret.Collection.ItemDeleted"><a id="org.freedesktop.Secret.Collection.ItemDeleted"></a><h3>
            <code class="literal">org.freedesktop.Secret.Collection.ItemDeleted</code>
          </h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">ItemDeleted</b>
              (</code></td><td>IN ObjectPath <var class="pdparam">item</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div><p>An item in this collection was deleted.</p><div class="glosslist"><dl><dt>
                <code class="literal">item</code>
              </dt><dd><p>The item that was deleted.</p></dd></dl></div></div><div class="refsection" title="org.freedesktop.Secret.Collection.ItemChanged"><a id="org.freedesktop.Secret.Collection.ItemChanged"></a><h3>
            <code class="literal">org.freedesktop.Secret.Collection.ItemChanged</code>
          </h3><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">
                <b class="fsfunc">ItemChanged</b>
              (</code></td><td>IN ObjectPath <var class="pdparam">item</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer">&#160;</div></div><p>An item in this collection changed.</p><div class="glosslist"><dl><dt>
                <code class="literal">item</code>
              </dt><dd><p>The item that was changed.</p></dd></dl></div></div></div><div class="refsection" title="D-Bus Properties"><a id="id1230064"></a><h2>D-Bus Properties</h2><p>
            Accessed using the org.freedesktop.DBus.Properties interface.
          </p><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">Array&lt;ObjectPath&gt;&#160;</span><span class="varname">Items&#160;</span>;</code><br /><p>Items in this collection.</p><code class="fieldsynopsis"><span class="modifier">READWRITE&#160;</span><span class="type">String&#160;</span><span class="varname">Label&#160;</span>;</code><br /><p>The displayable label of this collection.</p><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">Boolean&#160;</span><span class="varname">Locked&#160;</span>;</code><br /><p>
                    Whether the collection is locked and must be authenticated by the client application.
                </p><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">UInt64&#160;</span><span class="varname">Created&#160;</span>;</code><br /><p>The unix time when the collection was created.</p><code class="fieldsynopsis"><span class="modifier">READ&#160;</span><span class="type">UInt64&#160;</span><span class="varname">Modified&#160;</span>;</code><p>The unix time when the collection was last modified.</p></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="re01.html">Prev</a>&#160;</td><td width="20%" align="center"><a accesskey="u" href="ch13.html">Up</a></td><td width="40%" align="right">&#160;<a accesskey="n" href="re03.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">
          <code class="literal">org.freedesktop.Secret.Service</code>
        &#160;</td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top">&#160;
          <code class="literal">org.freedesktop.Secret.Item</code>
        </td></tr></table></div></body></html>