Open Monograph Press  3.3.0
ChapterAuthorDAO Class Reference
Inheritance diagram for ChapterAuthorDAO:
DAO

Public Member Functions

 _fromRow ($row)
 
 deleteChapterAuthorById ($authorId, $chapterId=null)
 
 deleteChapterAuthorsByChapterId ($chapterId)
 
 getAuthorIdsByChapterId ($chapterId)
 
 getAuthors ($publicationId=null, $chapterId=null)
 
 insertChapterAuthor ($authorId, $chapterId, $isPrimary=false, $sequence=0)
 
 newDataObject ()
 
- Public Member Functions inherited from DAO
 __construct ($dataSource=null, $callHooks=true)
 
 concat ()
 
 convertFromDB ($value, $type)
 
 convertToDB ($value, &$type)
 
 dateFromDB ($d)
 
 datetimeFromDB ($dt)
 
 datetimeToDB ($dt)
 
 dateToDB ($d)
 
 flushCache ()
 
 formatDateToDB ($date, $defaultNumWeeks=null, $acceptPastDate=true)
 
 getAdditionalFieldNames ()
 
 getAffectedRows ()
 
 getDataObjectSettings ($tableName, $idFieldName, $idFieldValue, $dataObject)
 
 getDataSource ()
 
 getDirectionMapping ($direction)
 
 getDriver ()
 
 getLocaleFieldNames ()
 
 getType ($value)
 
 handleError ($dataSource, $sql)
 
 nullOrInt ($value)
 
 replace ($table, $arrFields, $keyCols)
 
retrieve ($sql, $params=false, $callHooks=true)
 
retrieveCached ($sql, $params=false, $secsToCache=3600, $callHooks=true)
 
retrieveLimit ($sql, $params=false, $numRows=false, $offset=false, $callHooks=true)
 
retrieveRange ($sql, $params=false, $dbResultRange=null, $callHooks=true)
 
 setCacheDir ()
 
 setDataSource ($dataSource)
 
 update ($sql, $params=false, $callHooks=true, $dieOnError=true)
 
 updateDataObjectSettings ($tableName, $dataObject, $idArray)
 

Additional Inherited Members

- Static Public Member Functions inherited from DAO
static getDataChangedEvent ($elementId=null, $parentElementId=null, $content='')
 
- Data Fields inherited from DAO
 $_dataSource
 
- Protected Member Functions inherited from DAO
 _getInsertId ($table='', $id='')
 

Detailed Description

Definition at line 23 of file ChapterAuthorDAO.inc.php.

Member Function Documentation

◆ _fromRow()

ChapterAuthorDAO::_fromRow (   $row)

Internal function to return an Author object from a row.

Parameters
$rowarray
Returns
Author

Definition at line 144 of file ChapterAuthorDAO.inc.php.

References DAORegistry\getDAO(), and newDataObject().

◆ deleteChapterAuthorById()

ChapterAuthorDAO::deleteChapterAuthorById (   $authorId,
  $chapterId = null 
)

Remove an author from a chapter

Parameters
$chapterIdint

Definition at line 109 of file ChapterAuthorDAO.inc.php.

References DAO\update().

◆ deleteChapterAuthorsByChapterId()

ChapterAuthorDAO::deleteChapterAuthorsByChapterId (   $chapterId)

Remove all authors from a chapter

Parameters
$chapterIdint

Definition at line 124 of file ChapterAuthorDAO.inc.php.

References DAO\update().

◆ getAuthorIdsByChapterId()

ChapterAuthorDAO::getAuthorIdsByChapterId (   $chapterId)

Get all authors IDs for a given chapter.

Parameters
$chapterIdint
Returns
array

Definition at line 62 of file ChapterAuthorDAO.inc.php.

References DAO\retrieve().

◆ getAuthors()

ChapterAuthorDAO::getAuthors (   $publicationId = null,
  $chapterId = null 
)

Get all authors for a given chapter.

Parameters
$publicationIdint
$chapterIdint
Returns
DAOResultFactory

Definition at line 30 of file ChapterAuthorDAO.inc.php.

References DAO\retrieve().

◆ insertChapterAuthor()

ChapterAuthorDAO::insertChapterAuthor (   $authorId,
  $chapterId,
  $isPrimary = false,
  $sequence = 0 
)

Add an author to a chapter.

Parameters
$chapterIdint
$monographIdint
Returns
array

Definition at line 89 of file ChapterAuthorDAO.inc.php.

References DAO\update().

◆ newDataObject()

ChapterAuthorDAO::newDataObject ( )

Construct and return a new data object.

Returns
ChapterAuthor

Definition at line 135 of file ChapterAuthorDAO.inc.php.

Referenced by _fromRow().


The documentation for this class was generated from the following file: