* @return String|false The text of the current revision
* @deprecated as of 1.20, getContent() should be used instead.
*/
- public function getText( $audience = Revision::FOR_PUBLIC ) { #FIXME: deprecated, replace usage!
+ public function getText( $audience = Revision::FOR_PUBLIC ) { #@todo: deprecated, replace usage!
wfDeprecated( __METHOD__, '1.20' );
+
$this->loadLastEdit();
if ( $this->mLastRevision ) {
return $this->mLastRevision->getText( $audience );
* Get the text of the current revision. No side-effects...
*
* @return String|bool The text of the current revision. False on failure
+ * @deprecated as of 1.20, getContent() should be used instead.
*/
- public function getRawText() { #FIXME: deprecated, replace usage!
+ public function getRawText() { #@todo: deprecated, replace usage!
+ wfDeprecated( __METHOD__, '1.20' );
+
return $this->getText( Revision::RAW );
}
}
if ( $editInfo ) {
- $content = ContentHandler::makeContent( $editInfo->pst, $this->mTitle );
- # TODO: take model and format from edit info!
+ $content = $editInfo->pstContent;
} else {
$content = $this->getContent();
}
&& $parserOptions->getStubThreshold() == 0
&& $this->mTitle->exists()
&& ( $oldid === null || $oldid === 0 || $oldid === $this->getLatest() )
- && $this->getContentHandler()->isParserCacheSupported();
+ && $this->getContentHandler()->isParserCacheSupported();
}
/**
* @deprecated since 1.20: use ContentHandler::getUndoContent() instead.
*/
public function getUndoText( Revision $undo, Revision $undoafter = null ) { #FIXME: replace usages.
+ wfDeprecated( __METHOD__, '1.20' );
+
$this->loadLastEdit();
if ( $this->mLastRevision ) {
* @deprected since 1.20, use replaceSectionContent() instead
*/
public function replaceSection( $section, $text, $sectionTitle = '', $edittime = null ) { #FIXME: use replaceSectionContent() instead!
- // TODO FIXME
- //wfDeprecated( __METHOD__, '1.20' );
+ wfDeprecated( __METHOD__, '1.20' );
$sectionContent = ContentHandler::makeContent( $text, $this->getTitle() ); #XXX: could make section title, but that's not required.
* @param $user User The relevant user
* @param $comment String: comment submitted
* @param $minor Boolean: whereas it's a minor modification
+ *
+ * @deprecated since 1.20, use doEditContent() instead.
*/
public function doQuickEdit( $text, User $user, $comment = '', $minor = 0 ) {
- #TODO: log use of deprecated function
+ wfDeprecated( __METHOD__, "1.20" );
+
$content = ContentHandler::makeContent( $text, $this->getTitle() );
return $this->doQuickEditContent( $content, $user, $comment , $minor );
}