예제 #1
0
 public void Add(VideoStorageServer X)
 {
     List.Add(X);
 }
예제 #2
0
 public VideoStorageServer GetVideoStorageServer(int ID)
 {
     try
     {
         VideoStorageServer X = null;
         string sSQL = "Select * FROM tblVideoStorageServer WHERE ID = " + ID;
         DataTable DT = GetDataTable(sSQL);
         if(DT.Rows.Count > 0)
         {
             X = new VideoStorageServer();
             DataRow r = DT.Rows[0];
             X.mvarID = Convert.ToInt32((object)r[0]);
             X.mvarControlAddress = Convert.ToString((object)r[1]);
             X.mvarControlPort = Convert.ToInt32((object)r[2]);
             X.mvarCreatedDate = Convert.ToDateTime((object)r[3]);
             X.mvarUploadAddress = Convert.ToString((object)r[4]);
             X.mvarIsUploadFTP = Convert.ToBoolean((object)r[5]);
             X.mvarUniqueIdentifier = r[6].ToString();
             X.mvarStorageDirectory = Convert.ToString((object)r[7]);
             X.mvarTypeId = Convert.ToInt32((object)r[8]);
         }
         DT.Dispose();
         return X;
     }
     catch(Exception Err)
     {
         throw new ApplicationException(Err.Message);
     }
 }