foobar2000 SDK  2015-08-03
Public Member Functions | Protected Member Functions
playlist_dataobject_desc_v2abstract

#include <ole_interaction.h>

+ Inheritance diagram for playlist_dataobject_desc_v2:

Public Member Functions

void copy (playlist_dataobject_desc_v2 const &source)
 
virtual void get_side_data (t_size which, mem_block_container &out) const =0
 
const playlist_dataobject_desc_v2operator= (const playlist_dataobject_desc_v2 &source)
 
void set_from_playlist_manager (bit_array const &mask)
 
virtual void set_side_data (t_size which, const void *data, t_size size)=0
 
- Public Member Functions inherited from playlist_dataobject_desc
void copy (playlist_dataobject_desc const &source)
 
virtual void get_entry_content (t_size which, metadb_handle_list_ref out) const =0
 
virtual t_size get_entry_count () const =0
 
virtual void get_entry_name (t_size which, pfc::string_base &out) const =0
 
virtual void set_entry_content (t_size which, metadb_handle_list_cref content)=0
 
virtual void set_entry_count (t_size count)=0
 
virtual void set_entry_name (t_size which, const char *name)=0
 

Protected Member Functions

 ~playlist_dataobject_desc_v2 ()
 
- Protected Member Functions inherited from playlist_dataobject_desc
 ~playlist_dataobject_desc ()
 

Detailed Description

Definition at line 25 of file ole_interaction.h.

Constructor & Destructor Documentation

playlist_dataobject_desc_v2::~playlist_dataobject_desc_v2 ( )
inlineprotected

Definition at line 61 of file ole_interaction.h.

61 {}

Member Function Documentation

void playlist_dataobject_desc_v2::copy ( playlist_dataobject_desc_v2 const &  source)
inline

Definition at line 30 of file ole_interaction.h.

30  {
31  const t_size count = source.get_entry_count(); set_entry_count(count);
32  metadb_handle_list content; pfc::string8 name;
34  for(t_size walk = 0; walk < count; ++walk) {
35  source.get_entry_name(walk,name); source.get_entry_content(walk,content); source.get_side_data(walk, sideData);
36  set_entry_name(walk,name); set_entry_content(walk,content); set_side_data(walk, sideData.get_ptr(), sideData.get_size());
37  }
38  }
const void * get_ptr() const
virtual void set_entry_content(t_size which, metadb_handle_list_cref content)=0
size_t t_size
Definition: int_types.h:48
virtual void set_entry_count(t_size count)=0
virtual void set_entry_name(t_size which, const char *name)=0
virtual void set_side_data(t_size which, const void *data, t_size size)=0
mem_block_container implementation.
virtual void playlist_dataobject_desc_v2::get_side_data ( t_size  which,
mem_block_container out 
) const
pure virtual
const playlist_dataobject_desc_v2& playlist_dataobject_desc_v2::operator= ( const playlist_dataobject_desc_v2 source)
inline

Definition at line 59 of file ole_interaction.h.

59 {copy(source); return *this;}
void copy(playlist_dataobject_desc_v2 const &source)
void playlist_dataobject_desc_v2::set_from_playlist_manager ( bit_array const &  mask)
inline

Definition at line 40 of file ole_interaction.h.

40  {
42  const t_size pltotal = api->get_playlist_count();
43  const t_size total = mask.calc_count(true,0,pltotal);
44  set_entry_count(total);
45  t_size done = 0;
46  pfc::string8 name; metadb_handle_list content;
48  for(t_size walk = 0; walk < pltotal; ++walk) if (mask[walk]) {
49  pfc::dynamic_assert( done < total );
50  api->playlist_get_name(walk,name); api->playlist_get_all_items(walk,content);
51  set_entry_name(done,name); set_entry_content(done,content);
52  stream_writer_buffer_simple sideData; api->playlist_get_sideinfo(walk, &sideData, abort);
53  set_side_data(done,sideData.m_buffer.get_ptr(), sideData.m_buffer.get_size());
54  ++done;
55  }
56  pfc::dynamic_assert( done == total );
57  }
const t_item * get_ptr() const
Definition: array.h:213
abort_callback_impl abort_callback_dummy
virtual void set_entry_content(t_size which, metadb_handle_list_cref content)=0
void dynamic_assert(bool p_condition, const char *p_msg)
Definition: primitives.h:239
size_t t_size
Definition: int_types.h:48
virtual void set_entry_count(t_size count)=0
Helper template used to easily access core services. Usage: static_api_ptr_t<myclass> api; api->doso...
Definition: service.h:533
t_size get_size() const
Definition: array.h:130
virtual void set_entry_name(t_size which, const char *name)=0
virtual void set_side_data(t_size which, const void *data, t_size size)=0
pfc::array_t< t_uint8, pfc::alloc_fast > m_buffer
virtual void playlist_dataobject_desc_v2::set_side_data ( t_size  which,
const void *  data,
t_size  size 
)
pure virtual

The documentation for this class was generated from the following file: