Créer  Editer  FrontPage  Index  Chercher  Changements  History  RSS  Login

Gst::Index

class Gst::Index

Generates indexes on objects.

Class Methods

Gst::Index.new
This method returns a newly allocated Gst::Index object.

Instance Methods

add(id, *args)
Adds an entry into the index. The type of the entry depends of the number and kind of additional parameters.
  • For an ID type, args must be a String.
  • For a FORMAT type, args must be a Gst::Format.
  • For an ASSOCIATION type, args must contains an association flag (see GstAssocFlags), a Gst::Format and a value for the format.
  • For an OBJECT type, well you must wait, because it is not yet implemented.
  • args: additional parameters, see below.
  • id: the ID of the index writer.
  • Returns: a reference to the newly allocated entry in the index, as a Gst::EntryIndex? object.
certainty
This method returns the certainty of the index (see GstIndexCertainty).
certainty=(certainty)
Sets the certainty of the index.
  • certainty: the certainty to set (see GstIndexCertainty).
  • Returns: the given parameter 'certainty'.
commit(id)
Tells the index that the writer with the given ID is done with this index and is not going to write any more entries to it.
  • id: the writer that committed the index.
  • Returns: self.
get_assoc_entry(id, method, flags, format, value) { ... }
Finds the given format/value in the index. If a block is given, it will be called as a compare function, passing references to 2 Gst::IndexEntry objects, and waiting for a boolean as the return value.
  • flags: flags for the entry (see GstAssocFlags).
  • format: a Gst::Format object.
  • method: the lookup method to use (see GstIndexLookupMethod).
  • id: the ID of the index writer.
  • value: the value to find.
  • Returns: the entry associated with the value (as a Gst::IndexEntry object), or nil if the value is not found.
group
This method returns the ID of the current group.
  • Returns: the ID of the current group.
group=(group)
Sets the current group number to the given argument.
  • group: the number of the group to set.
  • Returns: the given parameter 'group'.
new_group
Creates a new group for the given index. It will be set as the current group.
  • Returns: the ID of the newly created group.
readable?
This method returns whether the index can be read.
  • Returns: whether the index can be read.
set_certainty(certainty)
Sets the certainty of the index.
set_group(group)
Sets the current group number to the given argument.
  • group: the number of the group to set.
  • Returns: true if the operation succeeded, false if the group did not exist.
writable?
This method returns whether the index can be written.
  • Returns: whether the index can be written.

Properties

resolver: GstIndexResolver (Read/Write)
Select a predefined object to string mapper.
Dernière modification:2011/06/14 16:55:49
Mots clef:
Références:[Gst::Index] [Gst::IndexEntry] [Gst::Object] [Gst::Element]