public function countPaymentJournals($criteria = null, $distinct = false, $con = null) { include_once 'lib/model/om/BasePaymentJournalPeer.php'; if ($criteria === null) { $criteria = new Criteria(); } elseif ($criteria instanceof Criteria) { $criteria = clone $criteria; } $criteria->add(PaymentJournalPeer::ACADEMIC_COST_ID, $this->getId()); return PaymentJournalPeer::doCount($criteria, $distinct, $con); }