remove all scope objects
321612
public void clear() {
	try {
	    Scope scope;
	    // Map.Entry entry,e;
	    // Map context;

	    // release all session scopes
	    Iterator<Entry<String, Map<String, Scope>>> sit = cfSessionContexts.entrySet().iterator();
	    Entry<String, Map<String, Scope>> sentry;
	    Map<String, Scope> context;
	    Iterator<Entry<String, Scope>> itt;
	    Entry<String, Scope> e;
	    PageContext pc = ThreadLocalPageContext.get();
	    while (sit.hasNext()) {
		sentry = sit.next();
		context = sentry.getValue();
		itt = context.entrySet().iterator();
		while (itt.hasNext()) {
		    e = itt.next();
		    scope = e.getValue();
		    scope.release(pc);
		}
	    }
	    cfSessionContexts.clear();

	    // release all application scopes
	    Iterator<Entry<String, Application>> ait = applicationContexts.entrySet().iterator();
	    Entry<String, Application> aentry;
	    while (ait.hasNext()) {
		aentry = ait.next();
		scope = aentry.getValue();
		scope.release(pc);
	    }
	    applicationContexts.clear();

	    // release server scope
	    if (server != null) {
		server.release(pc);
		server = null;
	    }

	}
	catch (Throwable t) {
	    ExceptionUtil.rethrowIfNecessary(t);
	}
    }
450737
def new_scope(self, new_scope={}):
        
        old_scopes, self.scopes = self.scopes, self.scopes.new_child(new_scope)
        yield
        self.scopes = old_scopes
944978
boolean removeLocalScope(TransactionScope<Txn> scope) {
        TransactionScope<Txn> existing = mLocalScope.get();
        if (existing == scope) {
            detachNotification(scope.getActiveTxn());
            mLocalScope.remove();
            return true;
        }
        return false;
    }
970479
public void removeAll()
    {
        if (m_aRecords != null)
        {
            for (int iArrayIndex = 0; iArrayIndex < MAX_RECORD_ARRAY_SIZE; iArrayIndex++)
            {   // Free the objects that are no longer used
                this.freeElement(m_aRecords[iArrayIndex]);
                m_aRecords[iArrayIndex] = null;
            }
            m_aRecords = null;
        }
        m_iRecordListStep = 1;
        m_iRecordListEnd = 0;
        m_iRecordListMax = 0; // Current size of the record list (records scanned) (-1 - unknown)
    }
979586
public static void removeAll() {
        InternalThreadLocalMap threadLocalMap = InternalThreadLocalMap.getIfSet();
        if (threadLocalMap == null) {
            return;
        }

        try {
            Object v = threadLocalMap.indexedVariable(variablesToRemoveIndex);
            if (v != null && v != InternalThreadLocalMap.UNSET) {
                @SuppressWarnings("unchecked")
                Set<FastThreadLocal<?>> variablesToRemove = (Set<FastThreadLocal<?>>) v;
                FastThreadLocal<?>[] variablesToRemoveArray =
                        variablesToRemove.toArray(new FastThreadLocal[0]);
                for (FastThreadLocal<?> tlv: variablesToRemoveArray) {
                    tlv.remove(threadLocalMap);
                }
            }
        } finally {
            InternalThreadLocalMap.remove();
        }
    }
637961
void closeAllScopeModules() {
        synchronized (puScopes) {
            for (String module : puScopes.keySet()) {
                close(module, false); //PK59717
            }
            puScopes.clear();
        }
    }
284344
public function setAllScopes()
    {
        $scopes = array();
        $reflectionClass = new \ReflectionClass(__CLASS__);
        foreach ($reflectionClass->getConstants() as $constantName => $constantValue) {
            if (strpos($constantName, 'SCOPE_') !== false) {
                $scopes = $constantValue;
            }
        }

        $this->setScopes($scopes);
    }
617710
def unpack_scope(cls, scope):
        """"""
        query = {}
        projection = {}
        options = {}

        if isinstance(scope, tuple):
            if len(scope) > 3:
                raise ValueError("Invalid scope")
            if len(scope) >= 1:
                query = scope[0]
            if len(scope) >= 2:
                projection = scope[1]
            if len(scope) == 3:
                options = scope[2]
        elif isinstance(scope, dict):
            query = scope
        else:
            raise ValueError("Invalid scope")

        return query, projection, options
620280
function clearOwnProperties(obj) {
  for (var prop in obj) {
    if (obj.hasOwnProperty(prop)) {
      obj[prop] = undefined;
    }
  }
}
953282
public void removeAll() {
        int size = size();
        if (size == 0) {
            return;
        }
        for (int i = 0, listSize = lists.size(); i < listSize; i++) {
            List<? extends T> list = lists.get(i);
            if (list instanceof ObservableList) {
                ((ObservableList) list).removeOnListChangedCallback(callback);
            }
        }
        lists.clear();
        modCount += 1;
        listeners.notifyRemoved(this, 0, size);
    }
1345525
def clear_optimizer(self):
        """"""
        self._optimized = False
        self._type2decls = {}
        self._type2name2decls = {}
        self._type2decls_nr = {}
        self._type2name2decls_nr = {}
        self._all_decls = None
        self._all_decls_not_recursive = None

        for decl in self.declarations:
            if isinstance(decl, scopedef_t):
                decl.clear_optimizer()
1204932
function cleanup()
    {
        // destroy loop variable(s)
        foreach ( $this->LoopVariablesNames as $varName )
            $this->Tpl->unsetVariable( $varName, $this->RootNamespace );
    }
791281
def pop_scope(self):
        """"""
        child_scope = self.stack.current.current.copy()
        self.stack.current.pop()
        parent_scope = self.stack.current.current.copy()
        self.stack.current.current = {
            key: child_scope[key] for key in child_scope if key in parent_scope
        }
826260
def delete_all
      @loaded_constants.each do |const_name|
        if Object.const_defined?(const_name)
          Object.send(:remove_const, const_name)
        end
      end
      Ichiban::HTMLCompiler::Context.clear_user_defined_helpers
    end
817399
function cleanObject(Object){
    delete Object.resolve;
    delete Object.reject;
    delete Object.resolveResult;
    delete Object.rejectResult;
    delete Object.launchPromise;
    delete Object.promiseFunc;
}
451622
function dispose (moduleNames, callback) {
                var nameOrArr, cb;

                if (typeof moduleNames === 'function') {
                    logger.debug('Disposing all modules on scope, ' + self.name);
                    nameOrArr = null;
                    cb = moduleNames;
                } else {
                    logger.debug({
                        message: 'Disposing module(s) on scope, ' + self.name,
                        moduleNames: moduleNames
                    });
                    nameOrArr = moduleNames;
                    cb = callback;
                }


                return optionalAsync(function () {
                    var results;

                    if (is.array(nameOrArr)) {
                        results = context.container.dispose(nameOrArr).disposed.concat(
                            context.singletonContainer.dispose(nameOrArr).disposed
                        );

                        return {
                            result: results.length === nameOrArr.length,
                            disposed: results
                        };
                    }

                    return context.container.dispose(nameOrArr) ||
                        context.singletonContainer.dispose(nameOrArr);
                }, new Error(), cb);
            }
173588
public void removeChildren() {
        log.trace("removeChildren of {}", name);
        for (IBasicScope child : children.keySet()) {
            removeChildScope(child);
        }
    }