68 parent::__construct( $title, $slots, $wikiId );
69 Assert::parameterType(
'object', $row,
'$row' );
71 $timestamp =
wfTimestamp( TS_MW, $row->ar_timestamp );
72 Assert::parameter(
is_string( $timestamp ),
'$row->rev_timestamp',
'must be a valid timestamp' );
74 $this->mArchiveId =
intval( $row->ar_id );
79 $this->mPageId =
isset( $row->ar_page_id ) ?
intval( $row->ar_page_id ) : $title->getArticleID();
84 $this->mParentId =
isset( $row->ar_parent_id ) ?
intval( $row->ar_parent_id ) :
null;
85 $this->mId =
isset( $row->ar_rev_id ) ?
intval( $row->ar_rev_id ) :
null;
86 $this->mComment = $comment;
88 $this->mTimestamp = $timestamp;
89 $this->mMinorEdit =
boolval( $row->ar_minor_edit );
90 $this->mDeleted =
intval( $row->ar_deleted );
91 $this->mSize =
isset( $row->ar_len ) ?
intval( $row->ar_len ) :
null;
92 $this->mSha1 = !empty( $row->ar_sha1 ) ? $row->ar_sha1 :
null;
110 return parent::getId();
120 if ( $this->mSize ===
null ) {
121 $this->mSize = $this->mSlots->computeSize();
134 if ( $this->mSha1 ===
null ) {
135 $this->mSha1 = $this->mSlots->computeSha1();
147 public function getUser( $audience = self::FOR_PUBLIC,
User $user =
null ) {
149 return parent::getUser( $audience, $user );
160 return parent::getComment( $audience, $user );
168 return parent::getTimestamp();
186class_alias( RevisionArchiveRecord::class,
'MediaWiki\Storage\RevisionArchiveRecord' );
and that you know you can do these things To protect your we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights These restrictions translate to certain responsibilities for you if you distribute copies of the or if you modify it For if you distribute copies of such a whether gratis or for a you must give the recipients all the rights that you have You must make sure that receive or can get the source code And you must show them these terms so they know their rights We protect your rights with two and(2) offer you this license which gives you legal permission to copy
wfTimestamp( $outputtype=TS_UNIX, $ts=0)
Get a timestamp string in one of various formats.
Represents a title within MediaWiki.
The User object encapsulates all of the user-specific settings (user_id, name, rights,...
return true to allow those checks to and false if checking is done & $user