1 package olr.om; 2 3 import java.util.List; 4 5 import org.apache.torque.util.Criteria; 6 7 /*** 8 * The skeleton for this class was autogenerated by Torque on: 9 * 10 * [Wed Jun 16 21:12:50 CEST 2004] 11 * 12 * You should add additional methods to this class to meet the 13 * application requirements. This class will only be generated as 14 * long as it does not already exist in the output directory. 15 */ 16 public class RdfUserPeer 17 extends olr.om.BaseRdfUserPeer 18 { 19 20 public static RdfUser getUser(String login, String password) 21 throws Exception { 22 23 Criteria criteria = new Criteria(); 24 criteria.add(RdfUserPeer.LOGIN, login); 25 criteria.add(RdfUserPeer.PASSWORD, password); 26 27 final List users = RdfUserPeer.doSelect(criteria); 28 assert(users.size() <= 1); 29 if(users.size() == 0) return null; 30 return (RdfUser)users.get(0); 31 } 32 }