Exemplo n.º 1
0
Arquivo: List.cs Projeto: jhogan/qed
 private void Load(MySqlDataReader dr)
 {
     SetId(Convert.ToInt32(dr["Id"]));
     this._key = Convert.ToString(dr["key_"]);
     this._value = Convert.ToString(dr["value"]);
     this._leaf = Convert.ToBoolean(dr["leaf"]);
     this._listName = Convert.ToString(dr["listName"]);
     this._parId = Convert.ToInt32(dr["parId"]);
     MarkOld();
 }
Exemplo n.º 2
0
 public Message(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 3
0
Arquivo: List.cs Projeto: jhogan/qed
 public Entry(MySqlDataReader dr, CatList catList)
 {
     Setup();
     _catList = catList;
     this.Load(dr);
 }
Exemplo n.º 4
0
 public Effort(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 5
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     _extId = Convert.ToInt32(dr["extId"]);
     this._effId = new EffortID(dr["type"].ToString() + _extId);
     _testedBy = Convert.ToString(dr["testedBy"]);
     _approved = Convert.ToBoolean(dr["approved"]);
     _pmResource = Convert.ToString(dr["pmResource"]);
     _webResource = Convert.ToString(dr["webResource"]);
     _dbResource = Convert.ToString(dr["dbResource"]);
     _uatApproved = Convert.ToBoolean(dr["uatApproved"]);
     _projectManager = Convert.ToString(dr["pmResource"]);
     _maxResource = Convert.ToString(dr["maxResource"]);
     _uatApprovedBy = Convert.ToString(dr["uatApprovedBy"]);
     _branchFileHierarchy = Convert.ToString(dr["branchFileHierarchy"]);
     _environment = Convert.ToString(dr["environment"]);
     if (Convert.ToChar(dr["type"]) == 'P')
         _effType = EffortType.Project;
     if (Convert.ToChar(dr["type"]) == 'T')
         _effType = EffortType.Ticket;
     this._desc = Convert.ToString(dr["desc_"]);
     _requester = Convert.ToString(dr["requestor"]);
     MarkOld();
 }
Exemplo n.º 6
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     this._clientId = Convert.ToInt32(dr["clientId"]);
     this._finalComments= Convert.ToString(dr["finalComments"]);
     this._rolledBack = Convert.ToBoolean(dr["rolledBack"]);
     this._rolledDate= Convert.ToDateTime(dr["rolledDate"]);
     this._scheduledDate = Convert.ToDateTime(dr["scheduledDate"]);
     this._rolledBy = Convert.ToString(dr["rolledBy"]);
     this.Rolled = Convert.ToBoolean(dr["rolled"]);
     MarkOld();
 }
Exemplo n.º 7
0
Arquivo: Groups.cs Projeto: jhogan/qed
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     string name = Convert.ToString(dr["Name"]);
     string[] splitName = System.Text.RegularExpressions.Regex.Split(name, " - ");
     if (splitName.Length == 1) {
         this._name = splitName[0].Trim();
         this._retired = false;
     }else{
         if (splitName[0] == "RETIRED") {
             this._retired = true;
             this._name = splitName[1].Trim();
         }else{
             this._retired = false;
             this._name = splitName[0].Trim();
         }
     }
     this._description = Convert.ToString(dr["Description"]);
     this._email = Convert.ToString(dr["Email"]);
     MarkOld();
 }
Exemplo n.º 8
0
 public Defect(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 9
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     if (dr.GetSchemaTable().Select("ColumnName = 'text'").Length == 1)  // Check the schema to determine if the "text" column is in it.
         this._text = Convert.ToString(dr["text"]);
     this._userEmail = Convert.ToString(dr["userEmail"]);
     this._rollClass = Convert.ToString(dr["rollClass"]);
     this._rollType = (RollType)Enum.Parse(Type.GetType("QED.Business.CodePromotion.RollType"), Convert.ToString(dr["rollType"]));
     if (dr["ts"] != DBNull.Value)
         this._dateTime = Convert.ToDateTime(dr["ts"]);
     MarkOld();
 }
Exemplo n.º 10
0
 public Server(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 11
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["id"]));
     this._desc = dr["desc_"].ToString();
     this._effId = Convert.ToInt32(dr["effId"]);
     this._rollId =  Convert.ToInt32(dr["rollId"]);
     this._resolver = dr["resolver"].ToString();
     this._createdBy = dr["createdBy"].ToString();
     //this._status = dr["Status"].ToString();
     this._forRoll = Convert.ToBoolean(dr["forRoll"]);
     MarkOld();
 }
Exemplo n.º 12
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     this._desc = Convert.ToString(dr["desc_"]);
     this._dnsName = Convert.ToString(dr["dnsName"]);
     MarkOld();
 }
Exemplo n.º 13
0
		/// <summary>
		/// Executes the query, and returns the first column of the first row in the 
		/// result set returned by the query. Extra columns or rows are ignored.
		/// </summary>
		/// <returns></returns>
		public object ExecuteScalar()
		{
			// There must be a valid and open connection.
			if (connection == null || connection.State != ConnectionState.Open)
				throw new InvalidOperationException("Connection must be valid and open");

			// Data readers have to be closed first
			if (connection.Reader != null)
				throw new MySqlException("There is already an open DataReader associated with this Connection which must be closed first.");

			arraySql = SplitSql( cmdText );

			updateCount = -1;
			MySqlDataReader reader = new MySqlDataReader(this, 0);
			reader.NextResult();
			object val = null;
			if (reader.Read())
				val = reader.GetValue(0);
			reader.Close();
			return val;
		}
Exemplo n.º 14
0
		/// <summary>
		/// Overloaded. Sends the CommandText to the Connection and builds a MySqlDataReader.
		/// </summary>
		/// <returns></returns>
		public MySqlDataReader ExecuteReader(CommandBehavior behavior)
		{
			// There must be a valid and open connection.
			if (connection == null || connection.State != ConnectionState.Open)
				throw new InvalidOperationException("Connection must be valid and open");

			// make sure all readers on this connection are closed
			if (connection.Reader != null)
				throw new InvalidOperationException("There is already an open DataReader associated with this Connection which must be closed first.");

			string sql = cmdText;

			if (0 != (behavior & CommandBehavior.KeyInfo))
			{
			}

			if (0 != (behavior & CommandBehavior.SchemaOnly))
			{
			}

			if (0 != (behavior & CommandBehavior.SequentialAccess))
			{
			}

			if (0 != (behavior & CommandBehavior.SingleResult))
			{
			}

			if (0 != (behavior & CommandBehavior.SingleRow))
			{
				sql = String.Format("SET SQL_SELECT_LIMIT=1;{0};SET sql_select_limit=-1;", cmdText);
			}

			arraySql = SplitSql( sql );

			updateCount = -1;
			MySqlDataReader reader = new MySqlDataReader(this, behavior);

			// move to the first resultset
			reader.NextResult();
			connection.Reader = reader;
			return reader;
		}
Exemplo n.º 15
0
        public void Load(MySqlDataReader dr)
        {
            SetId(Convert.ToInt32(dr["Id"]));
            this._effortId = Convert.ToInt32(dr["effId"]);
            this._rolloutId = Convert.ToInt32(dr["rollId"]);
            this._rolled = Convert.ToBoolean(dr["rolled"]);
            this._text = Convert.ToString(dr["text"]);
            this._reasonForCodeFix = Convert.ToString(dr["reasonForCodeFix"]);
            this._reasonForRollBack = Convert.ToString(dr["reasonForRollBack"]);
            if (dr["wasCodeFixed"] == DBNull.Value)
                this._codeFixed = -1;
            else
                this._codeFixed = Convert.ToInt32(dr["wasCodeFixed"]);

            this._departmentResponsibleForErrorId = Convert.ToInt32(dr["departmentResponsibleForErrorId"]);
            this._finalComments= Convert.ToString(dr["finalComment"]);
            MarkOld();
        }
Exemplo n.º 16
0
Arquivo: Times.cs Projeto: jhogan/qed
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     this._effId = Convert.ToInt32(dr["effId"]);
     this._rollId = Convert.ToInt32(dr["rollId"]);
     this._minutes = Convert.ToInt32(dr["minutes"]);
     this._date = Convert.ToDateTime(dr["date"]);
     this._user = Convert.ToString(dr["user"]);
     this._text = Convert.ToString(dr["text"]);
     MarkOld();
 }
Exemplo n.º 17
0
 public EffortRollout(MySqlDataReader dr)
 {
     Setup();
     this.Load(dr);
 }
Exemplo n.º 18
0
Arquivo: Times.cs Projeto: jhogan/qed
 public Time(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 19
0
 public Rollout(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 20
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     this._catalog = Convert.ToString(dr["catalog"]);
     this._encPasswd = Convert.ToString(dr["passwd"]);
     this._port = Convert.ToInt32(dr["port"]);
     this._protocol = (QED.Business.Protocol) Enum.Parse(typeof(QED.Business.Protocol), Convert.ToString(dr["protocol"]));
     this._serverId = Convert.ToInt32(dr["serverId"]);
     this._SSPI = Convert.ToBoolean(dr["sspi"]);
     this._systemName = Convert.ToString(dr["systemName"]);
     this._transport = (QED.Business.Transport) Enum.Parse(typeof(QED.Business.Transport), Convert.ToString(dr["transport"]));
     this._user = Convert.ToString(dr["user"]);
     MarkOld();
 }
Exemplo n.º 21
0
Arquivo: Groups.cs Projeto: jhogan/qed
 public Group(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 22
0
 public Connection(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 23
0
 public Effort(MySqlDataReader dr, bool loadExternal)
 {
     this.Load(dr);
     if (loadExternal)
         this.LoadExternal();
 }
Exemplo n.º 24
0
 public Client(MySqlDataReader dr)
 {
     this.Load(dr);
 }
Exemplo n.º 25
0
 public void LoadTicket(MySqlDataReader dr)
 {
     /*TODO: There are more ticket data we could get here but other table hits would be necessary */
     this._extId = Convert.ToInt32(dr["ID"]);
     this._overdue = (dr["overdue"] == DBNull.Value) ? false : Convert.ToBoolean(dr["overdue"]);
     if (dr["CreationDate"] != DBNull.Value)
         this._creationDate = Convert.ToDateTime(dr["CreationDate"]);
     if (dr["CloseDate"] != DBNull.Value)
         this._closeDate = Convert.ToDateTime(dr["CloseDate"]);
     if (dr["ClientId"] != DBNull.Value)
         this._clientId = Convert.ToInt32(dr["ClientId"]);
     if (dr["PriorityID"] != DBNull.Value)
         this._priorityID = Convert.ToInt32(dr["PriorityID"]);
 }
Exemplo n.º 26
0
 public void Load(MySqlDataReader dr)
 {
     Setup();
     SetId(Convert.ToInt32(dr["Id"]));
     this._text = Convert.ToString(dr["text"]);
     this._effId = Convert.ToInt32(dr["effId"]);
     this._rollId = Convert.ToInt32(dr["rollId"]);
     this._createdBy = Convert.ToString(dr["createdBy"]);
     MarkOld();
 }