src/libtsduck/dtv/tsTablesFactory.cpp
bool ts::TablesFactory::isDescriptorAllowed(const UString& desc_node_name, TID table_id) const
{
    auto it = desc_node_name.findSimilar(_descriptorTablesIds);
    if (it == _descriptorTablesIds.end()) {
        // Not a table-specific descriptor, allowed anywhere
        return true;
    }
    else {
        // Table specific descriptor, the table needs to be listed.
        do {
            if (table_id == it->second) {
                // The table is explicitly allowed.
                return true;
            }
        } while (++it != _descriptorTablesIds.end() && desc_node_name.similar(it->first));
        // The requested table if was not found.
        return false;
    }
}
//----------------------------------------------------------------------------
// Check if a descriptor is allowed in a table.
//----------------------------------------------------------------------------
Check if a descriptor is allowed in a table.
Check if a descriptor is allowed in a table .
bool ts::TablesFactory::isDescriptorAllowed(const UString& desc_node_name, TID table_id) const
{
    auto it = desc_node_name.findSimilar(_descriptorTablesIds);
    if (it == _descriptorTablesIds.end()) {
        return true;
    }
    else {
        do {
            if (table_id == it->second) {
                return true;
            }
        } while (++it != _descriptorTablesIds.end() && desc_node_name.similar(it->first));
        return false;
    }
}
bool ts :: TablesFactory :: isDescriptorAllowed ( const UString & desc_node_name , TID table_id ) const { auto it = desc_node_name . findSimilar ( _descriptorTablesIds ) ; if ( it == _descriptorTablesIds . end ( ) ) { return true ; } else { do { if ( table_id == it -> second ) { return true ; } } while ( ++ it != _descriptorTablesIds . end ( ) && desc_node_name . similar ( it -> first ) ) ; return false ; } }
Check if a descriptor is allowed in a table.
Check if a descriptor is allowed in a table .
// Not a table-specific descriptor, allowed anywhere // Table specific descriptor, the table needs to be listed. // The table is explicitly allowed. // The requested table if was not found.