Ejemplo n.º 1
0
        public static void LogEvent(LogType type, MessageDirection messageDirection, string description,
                                    DicomCommandType command, DicomDataSet dataset,
                                    StoreScu Client, SerializableDictionary <string, object> customInformation)
        {
            try
            {
                string   ae  = Client.AETitle;
                DicomNet net = Client as DicomNet;

                SerializableDictionary <string, object> logCustomInformation = DicomLogEntry.CustomInformationDicomMessage;
                if (customInformation != null)
                {
                    logCustomInformation = new SerializableDictionary <string, object>();
                    foreach (KeyValuePair <string, object> kvp in customInformation)
                    {
                        logCustomInformation.Add(kvp.Key, kvp.Value);
                    }
                    logCustomInformation.Add(DicomLogEntry.DicomMessageKey, DicomLogEntry.DicomMessageValue);
                }

                Logger.Global.Log("Auto Copy", Client.CurrentScp.AETitle, Client.CurrentScp.PeerAddress.ToString(),
                                  Client.CurrentScp.Port, net.IsAssociated() ? net.Association.Calling : ae,
                                  net.HostAddress != null ? net.HostAddress.ToString() : string.Empty,
                                  net.IsConnected() ? net.HostPort : -1, command, DateTime.Now, type,
                                  messageDirection, description, dataset, logCustomInformation);
            }
            catch (Exception exception)
            {
                Logger.Global.Exception("Auto Copy", exception);
            }
        }
Ejemplo n.º 2
0
 public void LogEvent
 (
     LogType enumType,
     MessageDirection enumMessageDirection,
     string strDescription,
     DicomCommandType command,
     DicomDataSet DatasetRootElement,
     SerializableDictionary <string, object> customInfo
 )
 {
 }
Ejemplo n.º 3
0
 public static void Log
 (
     string clientAe,
     string clientIp,
     int clientPort,
     DicomCommandType command,
     LogType logType,
     MessageDirection direction,
     DicomDataSet dataSet,
     string description
 )
 {
     if (__Server != null)
     {
         Logger.Global.Log(__Server.AETitle, __Server.HostAddress, __Server.HostPort, clientAe, clientIp, clientPort, command, DateTime.Now, logType, direction, description, dataSet, null);
     }
 }
Ejemplo n.º 4
0
 public static void Log
 (
     DicomNet client,
     DicomCommandType command,
     LogType logType,
     MessageDirection direction,
     DicomDataSet dataSet,
     string description
 )
 {
     Log(client.IsAssociated( ) ? client.Association.Calling : string.Empty,
         client.HostAddress,
         client.HostPort,
         command,
         logType,
         direction,
         dataSet,
         description);
 }