/// <summary>
 /// Deleted the stream with the passed name.
 /// </summary>
 /// <param name="name">Name of stream</param>
 public void DeleteStream(string name)
 {
     CheckDisposedStatus();
     
      //check the arguments
     if( null == name )
         throw new ArgumentNullException("name");
     
     StreamInfo streamInfo = new StreamInfo(this, name);
     if (streamInfo.InternalExists())
     {
         streamInfo.Delete();
     }
 }
        DeleteUseLicenseForUser(
            RightsManagementEncryptionTransform rmet,
            StreamInfo si,
            object param,
            ref bool stop
            )
        {
            ContentUser userToDelete = param as ContentUser;
            if (userToDelete == null)
            {
                throw new ArgumentException(SR.Get(SRID.CallbackParameterInvalid), "param");
            }

            ContentUser userFromStream = null;
            using (Stream stream = si.GetStream(FileMode.Open, FileAccess.Read))
            {
                using (BinaryReader utf8Reader = new BinaryReader(stream, Encoding.UTF8))
                {
                    userFromStream = rmet.LoadUserFromStream(utf8Reader);
                }
            }

            if (userFromStream.GenericEquals(userToDelete))
            {
                si.Delete();
            }
        }