Refresh a tag's last discussion details.

@return $this
185399
public function refreshLastPostedDiscussion()
    {
        if ($lastPostedDiscussion = $this->discussions()->latest('last_posted_at')->first()) {
            $this->setLastPostedDiscussion($lastPostedDiscussion);
        }

        return $this;
    }
555476
public function refreshLastUsed($sessionId, $lastUsed = null)
    {
        if ($sessionInformation = $this->getSessionInformation($sessionId)) {
            if ($sessionInformation->getLastUsed() !== $lastUsed) {
                $sessionInformation->refreshLastUsed($lastUsed);
                $this->saveSessionInformation($sessionInformation);
            }
        }
    }
972848
public function reIndex()
    {
        $tags = $this->select(['tags.id', 'taggables.tag_id as pivot_tag_id'])
            ->join('taggables', 'tags.id', '=', 'taggables.tag_id')
            ->get()->keyBy('id')->all();

        $this->whereNotIn('id', array_keys($tags))->delete();

        // dd($this->has($model->getMorphClass(), '=', 0)->toSql());
        //
        // The commentable relation on the Comment model will return either a
        // Post or Video instance, depending on which type of model owns the comment.
        // $commentable = $comment->commentable;
    }
683999
public function refresh()
    {
        $url = self::classUrl() . "?id=" . $this->instanceId();
        list($resp, $usedOpts) = self::request(self::METHOD_GET, $url);
        $body = isset($resp['data'][0]) ? $resp['data'][0] : null;
        $this->install($body, $usedOpts);
        return $this;
    }
317316
public function updateHref() {
		if ( $this->href !== null && !$this->isDisabled() ) {
			$this->button->setAttributes( [ 'href' => $this->href ] );
		} else {
			$this->button->removeAttributes( [ 'href' ] );
		}
		return $this;
	}
1134421
public function lastPage()
    {
        $last = Html::a($this->text['last'], $this->getUrl($this->pageTotal), ['title' => $this->text['last']]);

        $this->html['last'] = $this->hasListElement($last);

        return $this;
    }
1167473
public function refresh()
    {
        list($resp, $usedOpts) = self::request(self::METHOD_GET, self::instanceUrl());
        $body = isset($resp['data'][0]) ? $resp['data'][0] : null;
        $this->install($body, $usedOpts);
        return $this;
    }
986206
public function refresh()
    {
        /* @var $cache Cache */
        $cache = is_string($this->db->schemaCache) ? Yii::$app->get($this->db->schemaCache, false) : $this->db->schemaCache;
        if ($this->db->enableSchemaCache && $cache instanceof Cache) {
            TagDependency::invalidate($cache, $this->getCacheTag());
        }
        $this->_indexNames = [];
        $this->_indexes = [];
    }
156486
def set_last_access(self, tag):
        """"""
        import time
        # time defeats check that value didn't change

        self.buildstate.access.last = '{}-{}'.format(tag, time.time())
        self.buildstate.commit()
21873
protected function update_last_message( $overrides = [] ) {
		if ( $this->messages->isNotEmpty() ) {
			$this->messages->last()->update( $overrides );
		}

		return $this;
	}
85834
public function clear()
    {
        $expiry = $this->values['_expiry'] ?? null;
        parent::clear();
        $this->set('_changed', true);
        $this->set('_timestamp', time());
        if ($expiry)
            $this->setExpiry($expiry);
        return $this;
    }
923068
public function setLastPostedDiscussion(Discussion $discussion)
    {
        $this->last_posted_at = $discussion->last_posted_at;
        $this->last_posted_discussion_id = $discussion->id;
        $this->last_posted_user_id = $discussion->last_posted_user_id;

        return $this;
    }
1244371
public function Refresh()
    {
        $iPt = $this->getItemPointer();
        $this->GoToStart();
        while ($oTmp = $this->Next()) {
            if (false === $oTmp->sqlData || ($oTmp->dAmount <= 0)) {
                $this->RemoveArticle($oTmp);
            } else {
                // refresh stock from db
                $oTmp->RefreshDataFromDatabase();
            }
        }
        if ($iPt > $this->Length()) {
            $iPt = $this->Length();
        }
        $this->setItemPointer($iPt);
        $this->UpdateListData();
    }
1000285
protected function processCurrentTag()
	{
		// Invalidate current tag if tags are disabled and current tag would not close the last open
		// tag and is not a system tag
		if (($this->context['flags'] & self::RULE_IGNORE_TAGS)
		 && !$this->currentTag->canClose(end($this->openTags))
		 && !$this->currentTag->isSystemTag())
		{
			$this->currentTag->invalidate();
		}

		$tagPos = $this->currentTag->getPos();
		$tagLen = $this->currentTag->getLen();

		// Test whether the cursor passed this tag's position already
		if ($this->pos > $tagPos && !$this->currentTag->isInvalid())
		{
			// Test whether this tag is paired with a start tag and this tag is still open
			$startTag = $this->currentTag->getStartTag();

			if ($startTag && in_array($startTag, $this->openTags, true))
			{
				// Create an end tag that matches current tag's start tag, which consumes as much of
				// the same text as current tag and is paired with the same start tag
				$this->addEndTag(
					$startTag->getName(),
					$this->pos,
					max(0, $tagPos + $tagLen - $this->pos)
				)->pairWith($startTag);

				// Note that current tag is not invalidated, it's merely replaced
				return;
			}

			// If this is an ignore tag, try to ignore as much as the remaining text as possible
			if ($this->currentTag->isIgnoreTag())
			{
				$ignoreLen = $tagPos + $tagLen - $this->pos;

				if ($ignoreLen > 0)
				{
					// Create a new ignore tag and move on
					$this->addIgnoreTag($this->pos, $ignoreLen);

					return;
				}
			}

			// Skipped tags are invalidated
			$this->currentTag->invalidate();
		}

		if ($this->currentTag->isInvalid())
		{
			return;
		}

		if ($this->currentTag->isIgnoreTag())
		{
			$this->outputIgnoreTag($this->currentTag);
		}
		elseif ($this->currentTag->isBrTag())
		{
			// Output the tag if it's allowed, ignore it otherwise
			if (!($this->context['flags'] & self::RULE_PREVENT_BR))
			{
				$this->outputBrTag($this->currentTag);
			}
		}
		elseif ($this->currentTag->isParagraphBreak())
		{
			$this->outputText($this->currentTag->getPos(), 0, true);
		}
		elseif ($this->currentTag->isVerbatim())
		{
			$this->outputVerbatim($this->currentTag);
		}
		elseif ($this->currentTag->isStartTag())
		{
			$this->processStartTag($this->currentTag);
		}
		else
		{
			$this->processEndTag($this->currentTag);
		}
	}
25462
public function refresh()
    {
        if ($this->ID && $this->HailID) {
            try {
                $api_client = new Client();
                $data = $api_client->getOne($this);
            } catch (\Exception $ex) {
                return $this;
            }
            if (count($data) > 0) {
                $this->importHailData($data);
            }
        }

        return $this;
    }
585563
private function reset()
    {
        $this->state   = self::IN_TEXT;
        $this->tagType = null;
        $this->buffer  = '';
        $this->tokens  = array();
        $this->seenTag = false;
        $this->line    = 0;
        $this->otag    = '{{';
        $this->ctag    = '}}';
        $this->otagLen = 2;
        $this->ctagLen = 2;
    }
1349253
public function refresh(): void
    {
        $this->size = null;
        $this->lastModified = null;
        $this->isReadable = null;
        $this->isWritable = null;
        $this->exists = null;
        $this->created = null;
        $this->isSymLink = null;
        $this->isDir = null;
        $this->isFile = null;
        $this->isExecutable = null;
        $this->ownerId = null;
        $this->owner = null;
        $this->group = null;
        $this->groupId = null;
        $this->lastRead = null;
    }