コード例 #1
0
        public List <ProjectClassMethod> GetProjectClassMethodsForEcosystem(string ecosystem)
        {
            lock (updateLock)
            {
                SqlDataReader             reader  = SqlHelper.ExecuteReader(sqlConnection, "spProjectClassesLoadAllForEcosystem", ecosystem);
                List <ProjectClassMethod> records = new List <ProjectClassMethod>();
                while (reader.Read())
                {
                    ProjectClassMethod pair = new ProjectClassMethod();
                    pair.Project = Convert.ToString(reader["project"]);


                    pair.Parent           = Convert.ToString(reader["parent"]);
                    pair.ProjectIsFork    = Convert.ToBoolean(reader["projectIsFork"]);
                    pair.Package          = Convert.ToString(reader["package"]);
                    pair.ClassName        = Convert.ToString(reader["className"]);
                    pair.MethodName       = Convert.ToString(reader["methodName"]);
                    pair.MethodParameters = Convert.ToString(reader["methodParameters"]);
                    pair.SourceFilePath   = Convert.ToString(reader["SourceFilePath"]);
                    pair.StartingLine     = Convert.ToInt64(reader["StartingLine"]);
                    pair.EndingLine       = Convert.ToInt64(reader["EndingLine"]);
                    pair.StartingColumn   = Convert.ToInt64(reader["StartingColumn"]);
                    pair.EndingColumn     = Convert.ToInt64(reader["EndingColumn"]);

                    records.Add(pair);
                }
                reader.Close();
                return(records);
            }
        }
コード例 #2
0
 public bool ProjectClassesInsert(ProjectClassMethod pcm)
 {
     return(SqlHelper.ExecuteNonQuery(sqlConnection, "spProjectClassesInsert",
                                      pcm.Project,
                                      pcm.Parent,
                                      pcm.ProjectIsFork,
                                      pcm.Package,
                                      pcm.ClassName,
                                      pcm.MethodName,
                                      pcm.MethodParameters,
                                      pcm.SourceFilePath,
                                      pcm.StartingLine,
                                      pcm.EndingLine,
                                      pcm.StartingColumn,
                                      pcm.EndingColumn) > 0);
 }