Rygel.MediaFileItem – librygel-server – Vala Binding Reference

Rygel.MediaFileItem – librygel-server Reference Manual

# MediaFileItem

## Object Hierarchy:

## Description:

public abstract class MediaFileItem : MediaItem

Represents a file-accessible or http-accessible media item (music file, image file, video file, etc) with some pre-established metadata or a content placeholder for uploaded content.

Items representing non-file-accessible content should create their own MediaItem subclass.

All known sub-classes:

- ImageItem
- AudioItem

- PlaylistItem
- PhotoItem

- VideoItem
- MusicItem

Required by:

- VisualItem

Namespace: Rygel
Package: librygel-server

## Content:

### Properties:

- public string mime_type { set; get; }
  The mime type of the source content (this.uri). A null/empty value means that the mime-type is unknown
- public string dlna_profile { set; get; }
  The DLNA profile of the source content (this.uri). A null/empty value means that the DLNA profile is unknown
- public int64 size { set; get; }
- public bool place_holder { set; get; }
- public override OCMFlags ocm_flags { get; }

### Creation methods:

- public MediaFileItem (string id, MediaContainer parent, string title, string upnp_class)

### Methods:

- public override DataSource? create_stream_source_for_resource (HTTPRequest request, MediaResource resource) throws Error
- public virtual MediaResource get_primary_resource ()
  Subclasses override this method to create the type-specific primary MediaResource.
- public virtual string get_extension ()
  Return the file/uri extension that best represents the item's primary resource.
- protected string ext_from_mime_type (string mime_type)
- public virtual async void add_engine_resources ()
  Request the media engine for the resources it can provide for this item. Typically these are the transcoded resources.

### Fields:

- protected static Regex address_regex
- public static HashMap<string,string> mime_to_ext

### Inherited Members:

All known members inherited from class Rygel.MediaItem

- UPNP_CLASS

- description

All known members inherited from class Rygel.MediaObject

- id
- ref_id
- upnp_class
- date
- creator
- modified
- object_update_id
- artist
- genre
- parent

- parent_ref
- title
- ocm_flags
- apply_replacements
- get_uris
- get_primary_uri
- add_uri
- constructed
- get_writable

- get_writables
- get_resource_list
- get_resource_by_name
- serialize
- serialize_resource_list
- create_stream_source_for_resource
- compare_string_props
- compare_int_props
- parent_ptr

All known members inherited from class GLib.Object

- interface_find_property
- interface_install_property
- interface_list_properties
- @new
- new_valist
- newv
- new_with_properties
- add_toggle_ref
- add_weak_pointer
- bind_property
- connect
- constructed
- disconnect
- dispose
- dup_data
- dup_qdata
- force_floating

- freeze_notify
- @get
- get_class
- get_data
- get_property
- get_qdata
- get_type
- getv
- is_floating
- notify_property
- @ref
- ref_sink
- replace_data
- replace_qdata
- remove_toggle_ref
- remove_weak_pointer
- @set

- set_data
- set_data_full
- set_property
- set_qdata
- set_qdata_full
- set_valist
- setv
- steal_data
- steal_qdata
- thaw_notify
- unref
- watch_closure
- weak_ref
- weak_unref
- notify
- ref_count