/**
  * Retrieve a single object by pkey and type
  *
  * @param      int $type the type.
  * @param      int $pk the primary key.
  * @param      PropelPDO $con the connection to use
  * @return     EventNotificationTemplate
  */
 public static function retrieveTypeByPK($type, $pk, PropelPDO $con = null)
 {
     if (null !== ($obj = EventNotificationTemplatePeer::getInstanceFromPool((string) $pk))) {
         if ($obj->getType() != $type) {
             return null;
         }
         return $obj;
     }
     $criteria = new Criteria(EventNotificationTemplatePeer::DATABASE_NAME);
     $criteria->add(EventNotificationTemplatePeer::ID, $pk);
     $criteria->add(EventNotificationTemplatePeer::TYPE, $type);
     return EventNotificationTemplatePeer::doSelectOne($criteria, $con);
 }
 /**
  * Retrieve a single object by pkey.
  *
  * @param      int $pk the primary key.
  * @param      PropelPDO $con the connection to use
  * @return     EventNotificationTemplate
  */
 public static function retrieveByPK($pk, PropelPDO $con = null)
 {
     if (null !== ($obj = EventNotificationTemplatePeer::getInstanceFromPool((string) $pk))) {
         return $obj;
     }
     $criteria = new Criteria(EventNotificationTemplatePeer::DATABASE_NAME);
     $criteria->add(EventNotificationTemplatePeer::ID, $pk);
     $v = EventNotificationTemplatePeer::doSelect($criteria, $con);
     return !empty($v) > 0 ? $v[0] : null;
 }