~ubuntu-branches/ubuntu/trusty/rgtk2/trusty

« back to all changes in this revision

Viewing changes to man/gVolumeMonitorAdoptOrphanMount.Rd

  • Committer: Bazaar Package Importer
  • Author(s): Dirk Eddelbuettel
  • Date: 2010-11-03 11:35:46 UTC
  • mfrom: (1.3.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20101103113546-a7fi7jdxdebp0tw1
Tags: 2.20.1-1
* New upstream release

* debian/control: Set (Build-)Depends: to current R version
* debian/control: Set Standards-Version: to current version 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
\alias{gVolumeMonitorAdoptOrphanMount}
 
2
\name{gVolumeMonitorAdoptOrphanMount}
 
3
\title{gVolumeMonitorAdoptOrphanMount}
 
4
\description{
 
5
This function should be called by any \code{\link{GVolumeMonitor}}
 
6
implementation when a new \code{\link{GMount}} object is created that is not
 
7
associated with a \code{\link{GVolume}} object. It must be called just before
 
8
emitting the \code{mount.added} signal.
 
9
\strong{WARNING: \code{g_volume_monitor_adopt_orphan_mount} has been deprecated since version 2.20 and should not be used in newly-written code. Instead of using this function, \code{\link{GVolumeMonitor}}
 
10
implementations should instead create shadow mounts with the URI of
 
11
the mount they intend to adopt. See the proxy volume monitor in
 
12
gvfs for an example of this. Also see \code{\link{gMountIsShadowed}},
 
13
\code{\link{gMountShadow}} and \code{\link{gMountUnshadow}} functions.}
 
14
}
 
15
\usage{gVolumeMonitorAdoptOrphanMount(mount)}
 
16
\arguments{\item{\verb{mount}}{a \code{\link{GMount}} object to find a parent for}}
 
17
\details{If the return value is not \code{NULL}, the caller must associate the
 
18
returned \code{\link{GVolume}} object with the \code{\link{GMount}}. This involves returning
 
19
it in its \code{\link{gMountGetVolume}} implementation. The caller must
 
20
also listen for the "removed" signal on the returned object
 
21
and give up its reference when handling that signal
 
22
  
 
23
Similary, if implementing \code{\link{gVolumeMonitorAdoptOrphanMount}},
 
24
the implementor must take a reference to \code{mount} and return it in
 
25
its \code{\link{gVolumeGetMount}} implemented. Also, the implementor must
 
26
listen for the "unmounted" signal on \code{mount} and give up its
 
27
reference upon handling that signal.
 
28
  
 
29
There are two main use cases for this function.
 
30
  
 
31
One is when implementing a user space file system driver that reads
 
32
blocks of a block device that is already represented by the native
 
33
volume monitor (for example a CD Audio file system driver). Such
 
34
a driver will generate its own \code{\link{GMount}} object that needs to be
 
35
assoicated with the \code{\link{GVolume}} object that represents the volume.
 
36
  
 
37
The other is for implementing a \code{\link{GVolumeMonitor}} whose sole purpose
 
38
is to return \code{\link{GVolume}} objects representing entries in the users
 
39
"favorite servers" list or similar.}
 
40
\value{[\code{\link{GVolume}}]  the \code{\link{GVolume}} object that is the parent for \code{mount} or \code{NULL}
 
41
if no wants to adopt the \code{\link{GMount}}.}
 
42
\author{Derived by RGtkGen from GTK+ documentation}
 
43
\keyword{internal}