/// <summary> /// Searches and returns a row. If more than one is found, /// throws <see cref="ActiveRecordException"/> /// </summary> /// <param name="targetType">The target type</param> /// <param name="criteria">The criteria</param> /// <returns>A <c>targetType</c> instance or <c>null</c></returns> public static object FindOne(Type targetType, DetachedCriteria criteria) { return(ActiveRecordBase.FindOne(targetType, criteria)); }
/// <summary> /// Searches and returns a row. If more than one is found, /// throws <see cref="ActiveRecordException"/> /// </summary> /// <param name="targetType">The target type</param> /// <param name="detachedQuery">The query expression</param> /// <returns>A <c>targetType</c> instance or <c>null</c></returns> public static object FindOne(Type targetType, IDetachedQuery detachedQuery) { return(ActiveRecordBase.FindOne(targetType, detachedQuery)); }
/// <summary> /// Searches and returns the a row. If more than one is found, /// throws <see cref="ActiveRecordException"/> /// </summary> /// <param name="targetType">The target type</param> /// <param name="criterias">The criteria expression</param> /// <returns>A <c>targetType</c> instance or <c>null</c></returns> public static object FindOne(Type targetType, params ICriterion[] criterias) { return(ActiveRecordBase.FindOne(targetType, criterias)); }