public virtual void EventPropertyDelete(EventProperty entity)
 {
     TraceCallEnterEvent.Raise();
       try
       {
     m_DataContext.BeginNestedTran();
     try
     {
       m_DataContext.ndihdEventPropertyDelete(entity.EventID,
                                          entity.Name);
       m_DataContext.CommitNested();
     }
     catch
     {
       m_DataContext.RollbackNested();
       throw;
     }
     TraceCallReturnEvent.Raise();
     return;
       }
       catch (Exception ex)
       {
     ExceptionManager.Publish(ex);
     TraceCallReturnEvent.Raise(false);
     throw;
       }
 }
Ejemplo n.º 2
0
 // -------------------------------------------------------------------------------------
 /// <summary>
 /// Copy constructor.
 /// </summary>
 /// <param name="EventIDVal">Value of 'nEventID' field</param>
 /// <param name="NameVal">Value of 'cName' field</param>
 /// <param name="origInstance">Original document data to copy.</param>
 // -------------------------------------------------------------------------------------
 public EventProperty(DBInt EventIDVal,
                  DBString NameVal,
                  EventProperty origInstance)
     : base(EventIDVal, NameVal, origInstance)
 {
 }
Ejemplo n.º 3
0
 // -------------------------------------------------------------------------------------
 /// <summary>
 /// Copy constructor.
 /// </summary>
 /// <param name="origInstance">Original document data to copy.</param>
 // -------------------------------------------------------------------------------------
 public EventProperty(EventProperty origInstance)
     : base(origInstance)
 {
 }
 public virtual void EventPropertyUpdate(EventProperty entity)
 {
     TraceCallEnterEvent.Raise();
       try
       {
     m_DataContext.BeginNestedTran();
     try
     {
       int count;
       m_DataContext.ndihdEventPropertyUpdate(entity.EventID,
                                          entity.Name,
                                          entity.Value, out count);
       if (count == 0) throw new ServiceUpdateException();
       m_DataContext.CommitNested();
     }
     catch
     {
       m_DataContext.RollbackNested();
       throw;
     }
     TraceCallReturnEvent.Raise();
     return;
       }
       catch (Exception ex)
       {
     ExceptionManager.Publish(ex);
     TraceCallReturnEvent.Raise(false);
     throw;
       }
 }
 public virtual EventProperty EventPropertySelect(DBInt EventIDVal,
                                              DBString NameVal)
 {
     TraceCallEnterEvent.Raise();
       try
       {
     EventProperty result = null;
     DataSet entitySet = m_DataContext.ndihdEventPropertySelect(EventIDVal,
                                                            NameVal);
     if (entitySet.Tables[0].Rows.Count != 0)
     {
       result = new EventProperty(entitySet);
     }
     TraceCallReturnEvent.Raise();
     return result;
       }
       catch (Exception ex)
       {
     ExceptionManager.Publish(ex);
     TraceCallReturnEvent.Raise(false);
     throw;
       }
 }