summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--doc/servicelinking.mux3
-rw-r--r--src/ConfigParser.cpp3
-rw-r--r--src/MuxElements.cpp5
-rw-r--r--src/MuxElements.h1
4 files changed, 9 insertions, 3 deletions
diff --git a/doc/servicelinking.mux b/doc/servicelinking.mux
index 25425a8..fa9692c 100644
--- a/doc/servicelinking.mux
+++ b/doc/servicelinking.mux
@@ -33,6 +33,9 @@ linking {
; that the programmes are related in some way. (default true)
hard true
+ ; Linkage actuator flag. Se to false to disable a link
+ active true
+
; Whether this linkage set affects only one country or several. Linkage sets that
; include AMSS or DRM services need to have this set to true. (default false)
international false
diff --git a/src/ConfigParser.cpp b/src/ConfigParser.cpp
index e9fe91d..544f89c 100644
--- a/src/ConfigParser.cpp
+++ b/src/ConfigParser.cpp
@@ -99,6 +99,7 @@ static void parse_linkage(ptree& pt,
throw runtime_error("Invalid service linking definition");
}
+ bool active = pt_set.get("active", true);
bool hard = pt_set.get("hard", true);
bool international = pt_set.get("international", false);
@@ -109,7 +110,7 @@ static void parse_linkage(ptree& pt,
throw runtime_error("Invalid service linking definition");
}
- auto linkageset = make_shared<LinkageSet>(setuid, lsn, hard, international);
+ auto linkageset = make_shared<LinkageSet>(setuid, lsn, active, hard, international);
linkageset->keyservice = service_uid; // TODO check if it exists
auto pt_list = pt_set.get_child_optional("list");
diff --git a/src/MuxElements.cpp b/src/MuxElements.cpp
index fe7043a..c4682e4 100644
--- a/src/MuxElements.cpp
+++ b/src/MuxElements.cpp
@@ -750,10 +750,11 @@ unsigned short DabSubchannel::getSizeDWord() const
LinkageSet::LinkageSet(const std::string& name,
uint16_t lsn,
+ bool active,
bool hard,
bool international) :
lsn(lsn),
- active(true),
+ active(active),
hard(hard),
international(international),
m_name(name)
@@ -762,7 +763,7 @@ LinkageSet::LinkageSet(const std::string& name,
LinkageSet LinkageSet::filter_type(const ServiceLinkType type)
{
- LinkageSet lsd(m_name, lsn, hard, international);
+ LinkageSet lsd(m_name, lsn, active, hard, international);
lsd.active = active;
lsd.keyservice = keyservice;
diff --git a/src/MuxElements.h b/src/MuxElements.h
index f28a687..73637ac 100644
--- a/src/MuxElements.h
+++ b/src/MuxElements.h
@@ -463,6 +463,7 @@ class LinkageSet {
public:
LinkageSet(const std::string& name,
uint16_t lsn,
+ bool active,
bool hard,
bool international);