예제 #1
0
 public FormfileCollection FetchAll()
 {
     FormfileCollection coll = new FormfileCollection();
     Query qry = new Query(Formfile.Schema);
     coll.LoadAndCloseReader(qry.ExecuteReader());
     return coll;
 }
예제 #2
0
        /// <summary>
        /// Returns a Personnelfile by a user
        /// </summary>
        /// <returns></returns>
        public static Formfile FetchByPerson(Person person)
        {
            if (person == null)
            {
                throw new ArgumentNullException("person");
            }
            FormfileCollection candidateFiles = person.Formfiles();

            if (candidateFiles.Count > 0)
            {
                return(candidateFiles[0]);
            }
            return(null);
        }
예제 #3
0
 public FormfileCollection FetchByQuery(Query qry)
 {
     FormfileCollection coll = new FormfileCollection();
     coll.LoadAndCloseReader(qry.ExecuteReader()); 
     return coll;
 }
예제 #4
0
 public FormfileCollection FetchByID(object Id)
 {
     FormfileCollection coll = new FormfileCollection().Where("id", Id).Load();
     return coll;
 }