#------------------------------------------------------------
# Copyright (C) 2006 RoyaltyShare, Inc.   All Rights Reserved
#------------------------------------------------------------
package RPS::Track::TrackWithLicenses;
use strict;
use warnings;

use Data::Dumper;

use lib '/app/tools/common/lib';
use Common::RSApp;
use Common::Assert;

use lib '/app/tools/rps/lib';
use RPS::License::US::TrackLicenseList;
use RPS::Track::TrackSimple;
use base 'RPS::Track::TrackSimple';

sub _initProperties
{
	my ($self, $props) = @_;

    # Call the inherited method first.
    # 
    $self->SUPER::_initProperties($props);


    # Now add in the license list.
    #
    if($props->{track_id} > 0)
    {
        # !!! Do these license lists _really_ need to have all this loadSub state? 
        # !!! Do we _really_ need to spew out the entire publisher block, for example?
        #
        $self->{TrackLicenseList} = RPS::License::US::TrackLicenseList->new(trackID => $props->{track_id}, readOnly => 1, loadSubs => 0);
    }
}


###
1;# Play nicely.
###

