Do a reset to check document again
481386
boolean doResetCheck() {
    if(documents.isEmpty() || (documents.size() > 1 && noMultiReset)) {
      return false;
    }
    return documents.get(docNum).doresetCheck();
  }
594757
function Reset()
	{
		$this->SetTColor($this->colorConverter->convert(0, $this->PDFAXwarnings));
		$this->SetDColor($this->colorConverter->convert(0, $this->PDFAXwarnings));
		$this->SetFColor($this->colorConverter->convert(255, $this->PDFAXwarnings));
		$this->SetAlpha(1);
		$this->colorarray = '';

		$this->spanbgcolorarray = '';
		$this->spanbgcolor = false;
		$this->spanborder = false;
		$this->spanborddet = [];

		$this->ResetStyles();

		$this->HREF = '';
		$this->textparam = [];
		$this->SetTextOutline();

		$this->textvar = 0x00; // mPDF 5.7.1
		$this->OTLtags = [];
		$this->textshadow = '';

		$this->currentLang = $this->default_lang;  // mPDF 6
		$this->RestrictUnicodeFonts($this->default_available_fonts); // mPDF 6
		$this->SetFont($this->default_font, '', 0, false);
		$this->SetFontSize($this->default_font_size, false);

		$this->currentfontfamily = '';
		$this->currentfontsize = '';
		$this->currentfontstyle = '';

		/* -- TABLES -- */
		if ($this->tableLevel && isset($this->table[1][1]['cellLineHeight'])) {
			$this->SetLineHeight('', $this->table[1][1]['cellLineHeight']); // *TABLES*
		} else { 		/* -- END TABLES -- */
			if (isset($this->blk[$this->blklvl]['line_height']) && $this->blk[$this->blklvl]['line_height']) {
				$this->SetLineHeight('', $this->blk[$this->blklvl]['line_height']); // sets default line height
			}
		}

		$this->lSpacingCSS = '';
		$this->wSpacingCSS = '';
		$this->fixedlSpacing = false;
		$this->minwSpacing = 0;
		$this->SetDash(); // restore to no dash
		$this->dash_on = false;
		$this->dotted_on = false;
		$this->divwidth = 0;
		$this->divheight = 0;
		$this->cellTextAlign = '';
		$this->cellLineHeight = '';
		$this->cellLineStackingStrategy = '';
		$this->cellLineStackingShift = '';
		$this->oldy = -1;

		$bodystyle = [];
		if (isset($this->cssManager->CSS['BODY']['FONT-STYLE'])) {
			$bodystyle['FONT-STYLE'] = $this->cssManager->CSS['BODY']['FONT-STYLE'];
		}
		if (isset($this->cssManager->CSS['BODY']['FONT-WEIGHT'])) {
			$bodystyle['FONT-WEIGHT'] = $this->cssManager->CSS['BODY']['FONT-WEIGHT'];
		}
		if (isset($this->cssManager->CSS['BODY']['COLOR'])) {
			$bodystyle['COLOR'] = $this->cssManager->CSS['BODY']['COLOR'];
		}
		if (isset($bodystyle)) {
			$this->setCSS($bodystyle, 'BLOCK', 'BODY');
		}
	}
804889
function(){
			var ls;
			// right after setting a new hash and reloading, IE barfs on this occassionally (only the first time)
			try{
				if(FuncUnit.win && FuncUnit.win.document == null){
					return;
				}
			}catch(e){
				setTimeout(arguments.callee, 500);
				return;
			}
			
			if (lookingForNewDocument && FuncUnit.checkForNewDocument() ) {
				
				ls = loadSuccess;
				
				loadSuccess = null;
				if (ls) {
					FuncUnit.win.focus();
					FuncUnit.win.document.documentElement.tabIndex = 0;
					
					ls();
				}
			}
			
		setTimeout(arguments.callee, 500)
	}
102255
function() {
		// If running in Node.js, don't teardown.
		if(isNode()) {
			return;
		}

		var document = getDocument(),
			window = getGlobal();

		domEvents.removeDelegateListener(document.documentElement, "click", "a", this.anchorClickHandler);

		// Reset the changed `window.history` methods to their original values.
		canReflect.eachKey(methodsToOverwrite, function(method) {
			window.history[method] = this.originalMethods[method];
		}, this);

		domEvents.removeEventListener(window, "popstate", this.dispatchHandlers);
	}
1056011
def restart_agent(self, agent_id, **kwargs):
        ''''''
        host_medium = self.get_medium('host_agent')
        agent = host_medium.get_agent()
        d = host_medium.get_document(agent_id)
        # This is done like this on purpose, we want to ensure that document
        # exists before passing it to the agent (even though he would handle
        # this himself).
        d.addCallback(
            lambda desc: agent.start_agent(desc.doc_id, **kwargs))
        return d
705865
def copy_reset(self):
        """"""
        # Reset settings
        self._filters = []
        self._filter_or = False
        self._paginate = True
        self._paginate_count = 0
        self._result_count = None
        self._result_limit = 500
        self._result_start = 0
733898
def handle_no_document(self, item_session: ItemSession) -> Actions:
        '''
        '''
        self._waiter.reset()

        action = self.handle_response(item_session)

        if action == Actions.NORMAL:
            item_session.set_status(Status.skipped)

        return action
655894
function whenDocumentReady(callback, doc) {
  if (!isDocumentReady(doc)) {
    var checkReady = function() {
      if (doc.readyState === 'complete' ||
          doc.readyState === requiredReadyState) {
        doc.removeEventListener(READY_EVENT, checkReady);
        whenDocumentReady(callback, doc);
      }
    };
    doc.addEventListener(READY_EVENT, checkReady);
  } else if (callback) {
    callback();
  }
}
593458
private void refreshStash() throws ObjectSourceException {
        if (!stash.isEmpty()) {
            return;
        }
        try {
            if (SEARCH_NOT_STARTED.equals(token)) {
                beginSearch();
            } else if (token != null) {
                resumeSearch();
            }
        } catch (RemoteException e) {
            throw new ObjectSourceException(e);
        }
    }
416343
def invalidate(self, context, sid):
		""""""
		
		result = self._Document.get_collection().delete_one({'_id': sid})
		
		return result.deleted_count == 1
629185
public function reset()
    {
        $this->choiceCounter = 0;
        $this->setExploration(new SplStack());
        $this->setExplorationMarker(array());
        $this->setLastRendering(null);
        $this->setRenderingStack(new SplStack());
        $this->setXmlBaseStack(new SplStack());
        $this->setDocument(new DOMDocument('1.0', 'UTF-8'));
        $this->setStylesheets($this->getDocument()->createDocumentFragment());
        $this->setCurrentInteraction(null);
    }
744211
public void reset()
  {

    if (!m_hasBeenReset && m_shouldReset)
    {
      m_hasBeenReset = true;

      if (this.m_outputStream != null)
      {
        try
        {
          m_outputStream.close();
        }
        catch (java.io.IOException ioe){}
      }

      m_outputStream = null;

      // I need to look more carefully at which of these really
      // needs to be reset.
      m_countersTable = null;

      m_xcontext.reset();
      
      m_xcontext.getVarStack().reset();
      resetUserParameters();
      

      m_currentTemplateElements.removeAllElements();     
      m_currentMatchTemplates.removeAllElements();
      m_currentMatchedNodes.removeAllElements();
      
      m_serializationHandler = null;      
      m_outputTarget = null;
      m_keyManager = new KeyManager();
      m_attrSetStack = null;
      m_countersTable = null;
      m_currentTemplateRuleIsNull = new BoolStack();
      // m_xmlSource = null; // android-removed
      m_doc = DTM.NULL;
      // m_isTransformDone = false; // android-removed
      m_transformThread = null;

      // m_inputContentHandler = null;
      // For now, reset the document cache each time.
      m_xcontext.getSourceTreeManager().reset();
    }

    //    m_reportInPostExceptionFromThread = false;
  }
321725
def reset( self ):
        
        if not self.plugin():
            return False
        
        self.plugin().reset()
        self.refreshUi()
        
        return True
526110
function _check(){
            if(_checkReady(target)){
                clearInterval(timeHandle);
                timeHandle = null;
                _call();

                isReady = true;
            }               
        }
487533
def reset_all_changes(self):
        
        self.reset_changes()
        for value in self.values():
            if isinstance(value, Document) or isinstance(value, DocumentList):
                value.reset_all_changes()
113225
def reset(self):
        
        self.reached_limit = False
        self.count = 0
        self.seen.clear()
1146079
public function reset()
    {
        $this->page        = 1;
        $this->perPage     = null;
        $this->parsers     = [];
        $this->sorts       = [];
        $this->searchQuery = null;
        $this->rules       = [
            'page'     => 'numeric',
            'per_page' => 'numeric',
            'sort'     => 'string',
            'q'        => 'string',
        ];
    }