Top | ![]() |
![]() |
![]() |
![]() |
GDataDocumentsProperty * | gdata_documents_property_new () |
const gchar * | gdata_documents_property_get_key () |
const gchar * | gdata_documents_property_get_etag () |
const gchar * | gdata_documents_property_get_value () |
void | gdata_documents_property_set_value () |
const gchar * | gdata_documents_property_get_visibility () |
void | gdata_documents_property_set_visibility () |
GDataDocumentsProperty is a subclass of GDataParsable and represents a Google Drive Property Resource on a file object.
It allows applications to store additional metadata on a file, such as tags, IDs from other data stores, viewing preferences etc. Properties can be used to share metadata between applications, for example, in a workflow application.
Each GDataDocumentsProperty is characterized by a key-value pair (where value is optional, and takes empty string "" by default) and a visibility parameter. The visibility can take values "PUBLIC" for public properties and "PRIVATE" for private properties (default). Private properties are accessible only by the application which set them, but public properties can be read/written by other applications as well.
GDataDocumentsProperty *
gdata_documents_property_new (const gchar *key
);
Creates a new GDataEntry with the given ID and default properties.
Since: 0.17.11
const gchar *
gdata_documents_property_get_key (GDataDocumentsProperty *self
);
Returns the key of the property. This will never be NULL
or an empty string ("").
Since: 0.17.11
const gchar *
gdata_documents_property_get_etag (GDataDocumentsProperty *self
);
Returns the ETag of the property.
the property's ETag. The ETag will never be empty; it's either NULL
or a valid ETag.
[transfer none]
Since: 0.17.11
const gchar *
gdata_documents_property_get_value (GDataDocumentsProperty *self
);
Returns the value of the property.
In the case that this value is NULL
, the Property Resource corresponding to self
will be deleted from the properties array on a file's metadata, whereas in the case that it's empty string (""), it will be set as it is.
Since: 0.17.11
void gdata_documents_property_set_value (GDataDocumentsProperty *self
,const gchar *value
);
Sets “value” to value
, corresponding to the key.
In the case that value
is NULL
, the Property Resource corresponding to self
will be deleted from the properties array on a file's metadata, whereas in the case that it's empty string (""), it will be set as it is.
Since: 0.17.11
const gchar *
gdata_documents_property_get_visibility
(GDataDocumentsProperty *self
);
Returns the visibility status of the property.
GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PUBLIC
if the GDataDocumentsProperty is publicly visible to other
apps, GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PRIVATE
if the GDataDocumentsProperty is restricted to the application which
created it.
Since: 0.17.11
void gdata_documents_property_set_visibility (GDataDocumentsProperty *self
,const gchar *visibility
);
Sets “visibility” to GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PUBLIC
for
public properties and GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PRIVATE
for
private properties (default).
Since: 0.17.11
#define GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PUBLIC "PUBLIC"
The GDataDocumentsProperty having the visibility set to TRUE corresponds to having the visibility property on a Drive Property Resource set to "PUBLIC". This makes the Property Resource visible to other apps.
Since: 0.17.11
#define GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PRIVATE "PRIVATE"
The GDataDocumentsProperty having the visibility set to FALSE (default) corresponds to having the visibility property on a Drive Property Resource set to "PRIVATE". This makes the Property Resource accessible only by the app that created it.
Since: 0.17.11
typedef struct _GDataDocumentsProperty GDataDocumentsProperty;
All the fields in the GDataDocumentsProperty structure are private and should never be accessed directly.
Since: 0.17.11
typedef struct { } GDataDocumentsPropertyClass;
All the fields in the GDataDocumentsPropertyClass structure are private and should never be accessed directly.
Since: 0.17.11
“etag”
property“etag” gchar *
ETag of the property.
For more information, see the Properties Resource
Flags: Read / Write / Construct Only
Default value: NULL
Since: 0.17.11
“key”
property“key” gchar *
The key of this property.
For more information, see the Properties Resource
Flags: Read / Write
Default value: NULL
Since: 0.17.11
“value”
property“value” gchar *
The value of this property. By default, it takes the an empty string ("").
For more information, see the Properties Resource
Flags: Read / Write
Default value: NULL
Since: 0.17.11
“visibility”
property“visibility” gchar *
The visibility status of this property. The default value of
visibility is PRIVATE on a Drive Properties Resource object,
hence “visibility” is GDATA_DOCUMENTS_PROPERTY_VISIBILITY_PRIVATE
by default. A private property restricts its visibility to only the app which created it.
For more information, see the Properties Resource
Flags: Read / Write
Default value: NULL
Since: 0.17.11