Example #1
0
 public StreamingEncoder GetStreamingEncoder(int ID)
 {
     try
     {
         StreamingEncoder X = new StreamingEncoder();
         string sSQL = "Select * FROM tblStreamingEncoder WHERE ID = " + ID;
         DataTable DT = GetDataTable(sSQL);
         if(DT.Rows.Count > 0)
         {
             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.mvarStreamAddress = Convert.ToString((object)r[3]);
             X.mvarStreamPort = Convert.ToInt32((object)r[4]);
             X.mvarIsMulticast = Convert.ToBoolean((object)r[5]);
             X.mvarHasControlableCamera = Convert.ToBoolean((object)r[6]);
             X.mvarMediaBufferServerID = Convert.ToInt32((object)r[7]);
             X.mvarRoomID = Convert.ToInt32((object)r[8]);
             X.mvarCreatedDate = Convert.ToDateTime((object)r[9]);
             X.mvarUniqueIdentifier = r[10].ToString();
             X.mvarDescription = r[11].ToString();
             X.mvarStreamingHeader = r[12].ToString();
             X.mvarStreamingEncoderTypeID = Convert.ToInt32(r[13]);
         }
         else
             X = null;
         DT.Dispose();
         return X;
     }
     catch(Exception Err)
     {
         throw new ApplicationException(Err.Message);
     }
 }
Example #2
0
 public void Add(StreamingEncoder X)
 {
     List.Add(X);
 }