Beispiel #1
0
        public void Constructor()
        {
            PackagingUpdateEventArgs args = new PackagingUpdateEventArgs(PackagingOperationType.Package, PackagingUpdateType.Info, "test");

            Assert.Equal(PackagingOperationType.Package, args.Operation);
            Assert.Equal(PackagingUpdateType.Info, args.Type);
            Assert.Equal("test", args.Message);
        }
        /// <summary>
        ///     Event handler for events raised from the <see cref="SDK.Packaging"/> namespace; writes the message and operation to
        ///     the console window.
        /// </summary>
        /// <param name="sender">The object that raised the event.</param>
        /// <param name="args">The event arguments.</param>
        private static void Update(object sender, PackagingUpdateEventArgs args)
        {
            string prefix = string.Empty;

            if (args.Type == PackagingUpdateType.Verbose)
            {
                prefix = new string(' ', 4);
            }
            else if (args.Type == PackagingUpdateType.Success)
            {
                prefix = "√ ";
            }

            Console.WriteLine($"[{args.Operation.ToString()}]: {prefix}{args.Message}");
        }
Beispiel #3
0
 /// <summary>
 ///     Handles <see cref="PackagingOperation.Updated"/> events.
 /// </summary>
 /// <param name="sender">The event sender.</param>
 /// <param name="e">The event args.</param>
 private void Truster_Updated(object sender, PackagingUpdateEventArgs e)
 {
 }
 /// <summary>
 ///     Handles <see cref="PackagingOperation.Updated"/> events.
 /// </summary>
 /// <param name="sender">The event sender.</param>
 /// <param name="e">The event args.</param>
 private void Verifier_Updated(object sender, PackagingUpdateEventArgs e)
 {
 }
Beispiel #5
0
 /// <summary>
 ///     Handles <see cref="PackagingOperation.Updated"/> events.
 /// </summary>
 /// <param name="sender">The event sender.</param>
 /// <param name="e">The event args.</param>
 private void Extractor_Updated(object sender, PackagingUpdateEventArgs e)
 {
 }
 private void PackageVerifierUpdated(object sender, PackagingUpdateEventArgs e)
 {
     logger.Debug("     PackageVerifier: " + e.Message);
 }
 private void ManifestExtractorUpdated(object sender, PackagingUpdateEventArgs e)
 {
     logger.Debug("     ManifestExtractor: " + e.Message);
 }
 /// <summary>
 ///     Handles <see cref="PackagingOperation.Updated"/> events.
 /// </summary>
 /// <param name="sender">The event sender.</param>
 /// <param name="e">The event args.</param>
 private void Creator_Updated(object sender, PackagingUpdateEventArgs e)
 {
 }