Exemplo n.º 1
0
        public CSTAConfirmationEvent Parse(IStructReader reader)
        {
            Logger logger = LogManager.GetLogger("TSAPIClient");

            try
            {
                object result;

                logger.Info("CSTAChangeMonitorFilterConfParser.Parse: eventType=CSTA_CHANGE_MONITOR_FILTER_CONF");
                logger.Info("CSTAChangeMonitorFilterConfParser.Parse: try to read the CSTAChangeMonitorFilterConfEvent_t confirmation event...");

                if (reader.TryReadStruct(typeof(CSTAChangeMonitorFilterConfEvent_t), out result))
                {
                    logger.Info("CSTAChangeMonitorFilterConfParser.Parse: successfully read the CSTAChangeMonitorFilterConfEvent_t confirmation event!");

                    CSTAChangeMonitorFilterConfEvent_t changeMonitorFilter = (CSTAChangeMonitorFilterConfEvent_t)result;

                    CSTAConfirmationEvent cstaConfirmation = new CSTAConfirmationEvent
                    {
                        u = { changeMonitorFilter = changeMonitorFilter }
                    };

                    return(cstaConfirmation);
                }

                return(null);
            }
            catch (Exception err)
            {
                logger.Error(string.Format("Error in CSTAChangeMonitorFilterConfParser.Parse: {0}", err));
            }

            return(null);
        }
Exemplo n.º 2
0
 public ChangeMonitorFilterEventReturn(CstaConfirmationEvent a1)
 {
     Csta = a1.changeMonitorFilter;
 }