Lines Matching refs:this

241         if (!$this->deleteRootBlockElement) {
293 $wikiPath = $this->getSourcePath()->toWikiPath();
299 $url->addQueryParameter("context-id", $this->getRequestedContextPath()->getWikiId());
310 if (isset($this->mime)) {
311 return $this->mime;
330 if (!$this->isPathExecution()) {
334 if (isset($this->processedInstructions)) {
343 …$executionContext = ExecutionContext::getActualOrCreateFromEnv()->setExecutingMarkupHandler($this);
345 $useCache = $this->instructionsCache->useCache();
355 if (!$this->isPathExecution()) {
359 if ($this->hasExecuted) {
375 $depends['age'] = $this->getCacheAge();
376 if ($this->isFragment()) {
386 ->setRequestedContextPath($this->getRequestedContextPath())
387 ->setRequestedExecutingPath($this->getRequestedContextPath())
417 ->setExecutingMarkupHandler($this);
419 $useCache = $this->contentCache->useCache($depends);
435 $snippets = $this->getSnippets();
444 $snippetCache = $this->getSnippetCacheStore();
445 $this->outputCacheDependencies->rerouteCacheDestination($snippetCache);
465 $snippetCacheStore = $this->getSnippetCacheStore();
485 $snippetCacheFile = $this->getSnippetCacheStore()->cache;
503 if (isset($this->snippetCache)) {
504 return $this->snippetCache;
506 if ($this->isPathExecution()) {
517 return $this->outputCacheDependencies->getDependenciesCacheStore();
523 $cachePath = $this->outputCacheDependencies->getDependenciesCacheStore()->cache;
533 $this->processIfNeeded();
540 return $this->getContentCachePath();
552 $this->hasExecuted = true;
559 $extension = $this->getMime()->getExtension();
575 return $this;
578 $instructions = $this->getInstructions();
585 if ($this->deleteRootBlockElement) {
589 if (!isset($this->builderName)) {
590 $this->builderName = $this->getMime()->getExtension();
593 $executionContext->setExecutingMarkupHandler($this);
595 if ($this->isDocument()) {
596 … $markupRenderer = MarkupRenderer::createFromMarkupInstructions($instructions, $this)
597 ->setRequestedMime($this->getMime())
598 ->setRendererName($this->builderName);
602 … LogUtility::error("The renderer ({$this->builderName}) seems to have been not found");
604 $this->cacheAfterRendering = $markupRenderer->getCacheAfterRendering();
606 if (!isset($this->markupDynamicRender)) {
607 … $this->markupDynamicRender = MarkupDynamicRender::create($this->builderName);
609 $output = $this->markupDynamicRender->processInstructions($instructions);
624 $this->fetchString = serialize($output);
626 $this->fetchString = $output;
637 …if (!$this->isPathExecution() || $this->mime->getExtension() === MarkupRenderer::METADATA_EXTENSIO…
638 return $this;
647 if (in_array($this->getMime()->toString(), [Mime::XHTML, Mime::HTML])) {
657 $this->storeSnippets();
661 $this->removeSnippets();
669 $this->outputCacheDependencies->storeDependencies();
670 $this->outputCacheDependencies->rerouteCacheDestination($this->contentCache);
683 io_saveFile($this->contentCache->cache, $this->fetchString);
685 return $this;
705 $extension = $this->getMime()->getExtension();
717 $requestedCache = $this->getRequestedCache();
721 $cacheAge = $this->getCacheMaxAgeInSec($requestedCache);
722 return $this->cacheAfterRendering ? $cacheAge : 0;
730 return parent::__toString() . " ({$this->getSourceName()}, {$this->getMime()->toString()})";
740 return $this;
752 $path = $this->contentCache->cache;
759 return $this->outputCacheDependencies;
770 $this->processIfNeeded();
772 if (!$this->isPathExecution()) {
773 return $this->fetchString;
782 $path = $this->getContentCachePath();
793 if (!in_array($this->getMime()->getExtension(), ["html", "xhtml"])) {
797 if ($this->getSourcePath()->toWikiPath()->getDrive() !== WikiPath::MARKUP_DRIVE) {
812 $sourcePath = $this->getSourcePath();
822 return $this->requestedContextPath;
831 if (isset($this->markupSourcePath)) {
832 return $this->markupSourcePath;
844 return $this->getSourcePath();
853 return $this->getSourcePath();
867 $snippets = $this->getSnippets();
888 $snippets = $this->localSnippets;
902 $slotId = $this->getSourcePath()->toWikiPath()->getWikiId();
934 if (isset($this->parentMarkupHandler)) {
935 $this->parentMarkupHandler->addSnippet($snippet);
936 return $this;
939 if (!$this->isPathExecution()
940 && !$this->isNonPathStandaloneExecution
950 …LogUtility::warning("The execution ($this) is not a path execution. The snippet $snippet will not …
953 if (!in_array($this->getMime()->toString(), [Mime::XHTML, Mime::HTML])) {
954 …LogUtility::warning("The execution ($this) is not a HTML execution. The snippet $snippet will not …
958 $this->localSnippets[$snippetGuid] = $snippet;
959 return $this;
982 if (isset($this->markupSourcePath)) {
994 if (!$this->shouldProcess()) {
995 return $this;
998 $this->process();
999 return $this;
1011 if (isset($this->requestedInstructions)) {
1013 return $this->requestedInstructions;
1029 ->setIsDocument($this->isDoc)
1030 ->setRequestedContextPath($this->getRequestedContextPath());
1031 if ($this->isPathExecution()) {
1032 $fetcherMarkupBuilder->setRequestedExecutingPath($this->getExecutingPathOrFail());
1034 $fetcherMarkupBuilder->setRequestedMarkupString($this->markupString);
1052 return $this->isDoc;
1067 return XmlDocument::createXmlDocFromMarkup($this->getFetchString());
1074 …$globalSnippets = SnippetSystem::getFromContext()->getSnippetsForSlot($this->getRequestedExecuting…
1079 $allSnippets = array_merge($globalSnippets, $this->localSnippets);
1086 return $this->isDocument() === false;
1091 if (isset($this->markupString)) {
1092 return $this->markupString;
1095 $sourcePath = $this->getSourcePath();
1110 if (isset($this->contextData)) {
1111 return $this->contextData;
1113 …$this->contextData = MarkupPath::createPageFromPathObject($this->getRequestedContextPath())->getMe…
1114 return $this->contextData;
1121 if (isset($this->toc)) {
1122 return $this->toc;
1125 return TOC::createForPage($this->getRequestedExecutingPath())->getValue();
1132 …return Outline::createFromCallStack(CallStack::createFromInstructions($this->getInstructions()))->…
1139 $path = $this->instructionsCache->cache;
1145 $instructions = $this->getInstructions();
1148 $markupPath = MarkupPath::createPageFromPathObject($this->getRequestedExecutingPath());
1159 $this->processMetadataIfNotYetDone();
1160 return $this->meta;
1181 if (isset($this->meta)) {
1182 return $this;
1192 …$executionContext = ExecutionContext::getActualOrCreateFromEnv()->setExecutingMarkupHandler($this);
1200 if ($this->isPathExecution()) {
1205 if (FileSystems::exists($this->getMetaPathOrFail())) {
1207 $executingPath = $this->getExecutingPathOrFail();
1215 $depends['files'][] = $this->instructionsCache->cache;
1217 $useCache = $this->metaCache->useCache($depends);
1219 $this->meta = $actualMeta;
1220 return $this;
1229 $wikiId = $this->getRequestedExecutingPath()->toWikiPath()->getWikiId();
1250 $instructions = $this->getInstructions();
1268 $path = $this->getRequestedExecutingPath();
1292 $this->meta = $evt->result;
1304 p_save_metadata($wikiId, $this->meta);
1305 $this->metaCache->storeCache(time());
1311 return $this;
1320 if (isset($this->metaPath)) {
1321 return $this->metaPath;
1336 return $this->getRequestedExecutingPath();
1352 return $this->getMetadataPath();
1365 if (isset($this->processedInstructions)) {
1366 return $this;
1369 $markup = $this->getMarkupStringToExecute();
1371 ->setExecutingMarkupHandler($this);
1373 …rkupRenderer = MarkupRenderer::createFromMarkup($markup, $this->getExecutingPathOrNull(), $this->g…
1376 if (isset($this->instructionsCache)) {
1381 $this->instructionsCache->storeCache($instructions);
1383 $this->processedInstructions = $instructions;
1384 return $this;
1394 $cache = $this->getSnippetCacheStore()->cache;
1405 …return "({$this->getSourceName()}) to ({$this->builderName} - {$this->getMime()}) with context ({$
1413 if (!$this->isPathExecution()) {
1414 if (isset($this->markupString)) {
1415 $md5 = md5($this->markupString);
1417 } elseif (isset($this->requestedInstructions)) {
1426 return $this->getSourcePath()->toUriString();
1442 if (!$this->shouldInstructionProcess()) {
1444 $this->processedInstructions = $this->instructionsCache->retrieveCache();
1448 $this->processInstructions();
1451 return $this->processedInstructions;
1460 if (!isset($this->parentMarkupHandler)) {
1463 return $this->parentMarkupHandler;
1476 $this->hasExecuted = false;
1478 unset($this->contextData);
1480 $this->contextData = $row;
1482 $this->requestedInstructions = $requestedInstructions;
1483 return $this;