System.Windows.Media.LicenseAcquirer.AcquireLicenseAsync C# (CSharp) Method

AcquireLicenseAsync() public method

public AcquireLicenseAsync ( System.Guid keyId, ContentKeyType keyType, System.Guid serviceId ) : void
keyId System.Guid
keyType ContentKeyType
serviceId System.Guid
return void
		public void AcquireLicenseAsync (Guid keyId, ContentKeyType keyType, Guid serviceId)
		{
			Console.WriteLine ("System.Windows.Media.LicenseAcquirer.AcquireLicenseAsync: NIEX");
			throw new NotImplementedException ();
		}

Same methods

LicenseAcquirer::AcquireLicenseAsync ( Stream mediaStream ) : void
LicenseAcquirer::AcquireLicenseAsync ( byte mediaHeader ) : void

Usage Example

        private void Button_PlayReady_LicenseAcquisition_Click(object sender, RoutedEventArgs e)
        {
            LicenseAcquirer licenseAcquirer = new LicenseAcquirer();

            // TCR 185 : VID PlayReady License Acquisition
            // The License Acquisition MUST be done over SSL
            // There must be a user connected to Xbox Live for SSL to work and the application should handle that.
            licenseAcquirer.LicenseServerUriOverride = new Uri("https://playready.directtaps.net/PR2_00/svc/LiveTVRootLicenses/rightsmanager.asmx");

            // ChallengeCustomData adds a string to the LicenseChallenge that
            // the business logic on the License Server uses to determine what license
            // to send to the client.
            licenseAcquirer.ChallengeCustomData = "UserAccount:0";
            licenseAcquirer.AcquireLicenseCompleted += new EventHandler<AcquireLicenseCompletedEventArgs>(licenseAcquirer_AcquireLicenseCompleted);

            // Asynchronously acquire the root license.
            // Use an Empty ServiceID since PlayReady Domains are not supported on Xbox.
            licenseAcquirer.AcquireLicenseAsync(Guid.Empty);
        }