Attempts to delete all Minecraft Worlds with "TEMP_" in front of the name
@param currentWorld excludes this world from deletion, can be null
348511
public static void cleanupTemporaryWorlds(String currentWorld){
        List<WorldSummary> saveList;
        ISaveFormat isaveformat = Minecraft.getMinecraft().getSaveLoader();
        isaveformat.flushCache();

        try{
            saveList = isaveformat.getSaveList();
        } catch (AnvilConverterException e){
            e.printStackTrace();
            return;
        }

        String searchString = tempMark + AddressHelper.getMissionControlPort() + "_";

        for (WorldSummary s: saveList){
            String folderName = s.getFileName();
            if (folderName.startsWith(searchString) && !folderName.equals(currentWorld)){
                isaveformat.deleteWorldDirectory(folderName);
            }
        }
    }
150452
@Override
	public void listRemove(final T currentElement) throws FrameworkException {

		final T previousElement = listGetPrevious(currentElement);
		final T nextElement     = listGetNext(currentElement);

		if (currentElement != null) {

			if (previousElement != null) {
				unlinkNodes(getSiblingLinkType(), previousElement, currentElement);
			}

			if (nextElement != null) {
				unlinkNodes(getSiblingLinkType(), currentElement, nextElement);
			}
		}

		if (previousElement != null && nextElement != null) {

			Node previousNode = previousElement.getNode();
			Node nextNode     = nextElement.getNode();

			if (previousNode != null && nextNode != null) {

				linkNodes(getSiblingLinkType(), previousElement, nextElement);
			}

		}
	}
248689
private void deleteTemporaryProperties(Map<String, Set<String>> map) {
        Iterator<String> iterator = map.keySet().iterator();
        while (iterator.hasNext()) {
            String key = iterator.next();
            if (isTemporaryProperty(key)) {
                LOGGER.debug("Delete temporary field {} from the connection result", key);
                iterator.remove();
            }
        }
    }
902987
public void setSite(String value) {

        if ((value != null) && !value.equals(m_currentSite)) {
            m_currentSite = value;
            m_treeType = new HashMap<String, String>();
        }
    }
1078300
public void removeTempBlockMeta(TempBlockMeta tempBlockMeta) throws BlockDoesNotExistException {
    Preconditions.checkNotNull(tempBlockMeta, "tempBlockMeta");
    final long blockId = tempBlockMeta.getBlockId();
    final long sessionId = tempBlockMeta.getSessionId();
    TempBlockMeta deletedTempBlockMeta = mBlockIdToTempBlockMap.remove(blockId);
    if (deletedTempBlockMeta == null) {
      throw new BlockDoesNotExistException(ExceptionMessage.BLOCK_META_NOT_FOUND, blockId);
    }
    Set<Long> sessionBlocks = mSessionIdToTempBlockIdsMap.get(sessionId);
    if (sessionBlocks == null || !sessionBlocks.contains(blockId)) {
      throw new BlockDoesNotExistException(ExceptionMessage.BLOCK_NOT_FOUND_FOR_SESSION, blockId,
          mTier.getTierAlias(), sessionId);
    }
    Preconditions.checkState(sessionBlocks.remove(blockId));
    if (sessionBlocks.isEmpty()) {
      mSessionIdToTempBlockIdsMap.remove(sessionId);
    }
    reclaimSpace(tempBlockMeta.getBlockSize(), false);
  }
728063
@Override
	public void delete() throws JMSException
    {
        if (connection == null)
            throw new FFMQException("Temporary queue already deleted","QUEUE_DOES_NOT_EXIST");
            
        connection.deleteTemporaryQueue(name);
        connection = null;
    }
1316932
@Override
  public Collection<Realm> removeRealm(String realmName) {
    RealmSet set = null;
    if (realmName.equals(this.localRealmName)) {
      set = this.realmNameToRealmSet.get(realmName);
    }
    else {
      set = this.realmNameToRealmSet.remove(realmName);
      if (set != null) {
        Collection<Realm> present = set.values();
        allRealmsSet.remove(realmName);
        return new ArrayList<Realm>(present);
      }
    }

    return null;
  }
193352
public void setWorldClip(Rectangle clip) {
		if (clip == null) {
			clearWorldClip();
		} else {
			setWorldClip(clip.getX(), clip.getY(), clip.getWidth(), clip
					.getHeight());
		}
	}
12401
@Override
	public final void deleteTemporaryTopic(String topicName) throws JMSException
    {
        engine.deleteTopic(topicName);
        unregisterTemporaryTopic(topicName);
    }
955934
public void deleteCurrent(SITransaction simpTran)
  throws SISessionUnavailableException, SISessionDroppedException,
         SIIncorrectCallException,
         SIErrorException
  {
    if (TraceComponent.isAnyTracingEnabled() && CoreSPILockedMessageEnumeration.tc.isEntryEnabled())
      SibTr.entry(CoreSPILockedMessageEnumeration.tc, "deleteCurrent", this);
      
    checkValidState("deleteCurrent");
    
    _localConsumerPoint.checkNotClosed();
    
    if (!_messageAvailable)
    {
      if (TraceComponent.isAnyTracingEnabled() && CoreSPILockedMessageEnumeration.tc.isEntryEnabled())
        SibTr.exit(CoreSPILockedMessageEnumeration.tc, "deleteCurrent", "Invalid current Message");
        
      throw new SIIncorrectCallException(
        nls.getFormattedMessage("INVALID_MESSAGE_ERROR_CWSIP0191", 
          new Object[] { _localConsumerPoint.getConsumerManager().getDestination().getName(),
            _localConsumerPoint.getConsumerManager().getMessageProcessor().getMessagingEngineName() }, 
          null));
    }
    
    _singleMessage = null;
    _messageAvailable = false;
    
    if (TraceComponent.isAnyTracingEnabled() && CoreSPILockedMessageEnumeration.tc.isEntryEnabled())
      SibTr.exit(CoreSPILockedMessageEnumeration.tc, "deleteCurrent");
  }
359540
protected void deleteTempFile() {

        try {
            // switch to the temporary file project
            switchToTempProject();
            // delete the temporary file
            getCms().deleteResource(getParamTempfile(), CmsResource.DELETE_PRESERVE_SIBLINGS);
        } catch (CmsException e) {
            // should usually never happen
            if (LOG.isInfoEnabled()) {
                LOG.info(e);
            }
        } finally {
            try {
                // switch back to the current project
                switchToCurrentProject();
            } catch (CmsException e) {
                // should usually never happen
                if (LOG.isInfoEnabled()) {
                    LOG.info(e);
                }
            }
        }
    }
1363552
public static void purgeTempFiles(String tempdir) {
		if (tempdir == null) return;

		s_logger.info("Removing: "+tempdir);
		Path dlPath = Paths.get(tempdir).resolve("chemcomp");
		File[] chemCompOutFiles = finder(dlPath.toString(), "cif.gz");
		if (null != chemCompOutFiles) for (File f : chemCompOutFiles) f.delete();
		dlPath.toFile().delete();
	}
1036638
@Override
    public void deleteTemporaryDestination(SIDestinationAddress destAddr)
                    throws SIConnectionUnavailableException, SIConnectionDroppedException,
                    SIErrorException,
                    SIDestinationLockedException, SITemporaryDestinationNotFoundException, SIResourceException, SIIncorrectCallException
    {
        if (TraceComponent.isAnyTracingEnabled() && CoreSPIConnection.tc.isEntryEnabled())
            SibTr.entry(CoreSPIConnection.tc, "deleteTemporaryDestination",
                        new Object[] { this, destAddr });

        // Synchronize on the close object, we don't want the connection closing
        // while we try to delete the destination.
        synchronized (this)
        {
            // See if this connection has been closed
            checkNotClosed();

            if (destAddr == null)
            {
                SIIncorrectCallException e =
                                new SIIncorrectCallException(
                                                nls_cwsir.getFormattedMessage(
                                                                              "CREATE_PRODUCER_CWSIR0071",
                                                                              null,
                                                                              null));
                if (TraceComponent.isAnyTracingEnabled() && CoreSPIConnection.tc.isEntryEnabled() && tc.isEntryEnabled())
                    SibTr.exit(tc, "deleteTemporaryDestination", e);

                throw e;
            }

            // Synchronize on the temporaryDestinations list object so that we can't collide
            // on creations. This will also ensure list integrity.
            synchronized (_temporaryDestinations)
            {
                //verify this temporary destination is in current list
                int index = _temporaryDestinations.indexOf(destAddr.getDestinationName());
                if (index == -1)
                {
                    if (TraceComponent.isAnyTracingEnabled() && CoreSPIConnection.tc.isEntryEnabled())
                        SibTr.exit(tc, "deleteTemporaryDestination", "SITemporaryDestinationNotFoundException");
                    throw new SIMPTemporaryDestinationNotFoundException(
                                    nls.getFormattedMessage(
                                                            "TEMPORARY_DESTINATION_NAME_ERROR_CWSIP0097",
                                                            new Object[] { destAddr },
                                                            null));
                }

                //pass to the destination manager
                _destinationManager.deleteTemporaryDestination((JsDestinationAddress) destAddr);

                //remove entry from list
                _temporaryDestinations.remove(index);
            }
        }

        if (TraceComponent.isAnyTracingEnabled() && CoreSPIConnection.tc.isEntryEnabled())
            SibTr.exit(CoreSPIConnection.tc, "deleteTemporaryDestination");
    }
1372986
public synchronized void delete() {
		try {
			clear();
		} catch (Exception ign) {
		}
		try {
			close();
		} catch (Exception ign) {
		}
		try {
			fileRedo.delete();
		} catch (Exception ign) {
		}
		try {
			fileStorage.delete();
		} catch (Exception ign) {
		}
		try {
			fileFreeBlocks.delete();
		} catch (Exception ign) {
		}
	}
978270
private void deleteTemporaryDestination(Destination destination) {
        log.debug("Delete temporary destination: '{}'", destination);

        try {
            if (destination instanceof TemporaryQueue) {
                ((TemporaryQueue) destination).delete();
            } else if (destination instanceof TemporaryTopic) {
                ((TemporaryTopic) destination).delete();
            }
        } catch (JMSException e) {
            log.error("Error while deleting temporary destination '" + destination + "'", e);
        }
    }
308317
public void removeTempTable(String tempTableName) throws SQLException {
        if (tempTableName == null) {
            return;
        }
        if (!tempTableName.contains(TEMP_TABLE_NAME_SUFFIX)) {
            throw new SQLException(tempTableName + " is not a valid temp table name");
        }
        try (Connection conn = this.getConn(); Statement stmt = conn.createStatement()) {
            final String sql = "DROP TABLE " + tempTableName + ";";
            LOG.debug("{} executing update: {}", this.dbInfo, sql);
            int row = stmt.executeUpdate(sql);
        }
    }
1330185
public static String getWorldGroupOfPlayerCurrentlyIn(String playerName) {
        return Common.getInstance().getWorldGroupManager().getWorldGroupName(getWorldPlayerCurrentlyIn(playerName));
    }