Exemple #1
0
        /// <summary>
        /// Logs remoting fragment data to verbose channel.
        /// </summary>
        /// <param name="id"></param>
        /// <param name="opcode"></param>
        /// <param name="task"></param>
        /// <param name="keyword"></param>
        /// <param name="objectId"></param>
        /// <param name="fragmentId"></param>
        /// <param name="isStartFragment"></param>
        /// <param name="isEndFragment"></param>
        /// <param name="fragmentLength"></param>
        /// <param name="fragmentData"></param>
        internal static void LogAnalyticVerbose(PSEventId id, PSOpcode opcode, PSTask task, PSKeyword keyword,
                                                Int64 objectId,
                                                Int64 fragmentId,
                                                int isStartFragment,
                                                int isEndFragment,
                                                UInt32 fragmentLength,
                                                PSETWBinaryBlob fragmentData)
        {
            if (provider.IsEnabled(PSLevel.Verbose, keyword))
            {
                string payLoadData = BitConverter.ToString(fragmentData.blob, fragmentData.offset, fragmentData.length);
                payLoadData = string.Format(CultureInfo.InvariantCulture, "0x{0}", payLoadData.Replace("-", ""));

                provider.WriteEvent(id, PSChannel.Analytic, opcode, PSLevel.Verbose, task, keyword,
                                    objectId, fragmentId, isStartFragment, isEndFragment, fragmentLength,
                                    payLoadData);
            }
        }
Exemple #2
0
 /// <summary>
 /// Logs information to the operational channel.
 /// </summary>
 /// <param name="id"></param>
 /// <param name="opcode"></param>
 /// <param name="task"></param>
 /// <param name="keyword"></param>
 /// <param name="args"></param>
 internal static void LogOperationalInformation(PSEventId id, PSOpcode opcode, PSTask task, PSKeyword keyword, params object[] args)
 {
     provider.WriteEvent(id, PSChannel.Operational, opcode, PSLevel.Informational, task, keyword, args);
 }