From 05c1a838c881ea502888659848d8792843b28718 Mon Sep 17 00:00:00 2001 From: Luca Muscariello Date: Sat, 25 Feb 2017 23:42:31 +0100 Subject: Initial commit: video player - viper Change-Id: Id5aa33598ce34659bad4a7a9ae5006bfb84f9bd1 Signed-off-by: Luca Muscariello --- libdash/source/mpd/ContentComponent.cpp | 98 +++++++++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) create mode 100644 libdash/source/mpd/ContentComponent.cpp (limited to 'libdash/source/mpd/ContentComponent.cpp') diff --git a/libdash/source/mpd/ContentComponent.cpp b/libdash/source/mpd/ContentComponent.cpp new file mode 100644 index 00000000..ce3de857 --- /dev/null +++ b/libdash/source/mpd/ContentComponent.cpp @@ -0,0 +1,98 @@ +/* + * ContentComponent.cpp + ***************************************************************************** + * Copyright (C) 2012, bitmovin Softwareentwicklung OG, All Rights Reserved + * + * Email: libdash-dev@vicky.bitmovin.net + * + * This source code and its use and distribution, is subject to the terms + * and conditions of the applicable license agreement. + *****************************************************************************/ + +#include "ContentComponent.h" + +using namespace dash::mpd; + +ContentComponent::ContentComponent () : + id(0), + lang(""), + contentType(""), + par("") +{ +} +ContentComponent::~ContentComponent () +{ + for(size_t i = 0; i < this->accessibility.size(); i++) + delete(this->accessibility.at(i)); + for(size_t i = 0; i < this->role.size(); i++) + delete(this->role.at(i)); + for(size_t i = 0; i < this->rating.size(); i++) + delete(this->rating.at(i)); + for(size_t i = 0; i < this->viewpoint.size(); i++) + delete(this->viewpoint.at(i)); +} + +const std::vector& ContentComponent::GetAccessibility () const +{ + return (std::vector &)this->accessibility; +} +void ContentComponent::AddAccessibity (Descriptor *accessibility) +{ + this->accessibility.push_back(accessibility); +} +const std::vector& ContentComponent::GetRole () const +{ + return (std::vector &)this->role; +} +void ContentComponent::AddRole (Descriptor *role) +{ + this->role.push_back(role); +} +const std::vector& ContentComponent::GetRating () const +{ + return (std::vector &)this->rating; +} +void ContentComponent::AddRating (Descriptor *rating) +{ + this->rating.push_back(rating); +} +const std::vector& ContentComponent::GetViewpoint () const +{ + return (std::vector &)this->viewpoint; +} +void ContentComponent::AddViewpoint (Descriptor *viewpoint) +{ + this->viewpoint.push_back(viewpoint); +} +uint32_t ContentComponent::GetId () const +{ + return this->id; +} +void ContentComponent::SetId (uint32_t id) +{ + this->id = id; +} +const std::string& ContentComponent::GetLang () const +{ + return this->lang; +} +void ContentComponent::SetLang (const std::string& lang) +{ + this->lang = lang; +} +const std::string& ContentComponent::GetContentType () const +{ + return this->contentType; +} +void ContentComponent::SetContentType (const std::string& contentType) +{ + this->contentType = contentType; +} +const std::string& ContentComponent::GetPar () const +{ + return this->par; +} +void ContentComponent::SetPar (const std::string& par) +{ + this->par = par; +} -- cgit 1.2.3-korg