Remove a CTS record
        :param map:
        :param position:
        :return:
320352
def remove_cts_record(self, map, position):
        
        def _key1(pos):
            return '%s/cts100record/crypto_idfp%s' % (map, pos)

        def _key2(pos):
            return '%s/cts100record/time%s' % (map, pos)

        for i in range(position, 100):
            if _key1(i) in self:
                del self[_key1(i)]
            if _key2(i) in self:
                del self[_key2(i)]
            if _key1(i+1) in self:
                self[_key1(i)] = self[_key1(i+1)]
            if _key2(i+1) in self:
                self[_key2(i)] = self[_key2(i+1)]
467354
def erase(ctx):
    
    if os.path.exists(ctx.obj['report']):
        os.remove(ctx.obj['report'])
490997
def pop(self, key, default=_marker):
        
        try:
            popped = self[key]
            del self[key]
            return popped
        except KeyError:
            if default == _marker:
                raise
            return default
349024
public void excludePositions(ArrayList<Integer> positions) {
    for (Integer p : positions) {
      if (realTSindex.containsKey(p)) {
        SAXRecord rec = realTSindex.get(p);
        rec.removeIndex(p);
        if (rec.getIndexes().isEmpty()) {
          this.records.remove(String.valueOf(rec.getPayload()));
        }
        realTSindex.remove(p);
      }
    }
  }
149631
def pop(self, key, *args):
        ''
        try:
            return self.maps[0].pop(key, *args)
        except KeyError:
            raise KeyError('Key not found in the first mapping: {!r}'.format(key))
212937
public static <MK> void removeAtomicMap(Cache<MK, ?> cache, MK key) {
      // This removes any entry from the cache but includes special handling for fine-grained maps
      FineGrainedAtomicMapProxyImpl.removeMap((Cache<Object, Object>) cache, key);
   }
676685
public void removePhysicalPosition(final long iPosition) throws IOException {
    final long position = iPosition * RECORD_SIZE;

    acquireExclusiveLock();
    try {

      final long[] pos = fileSegment.getRelativePosition(position);
      final OFile file = fileSegment.files[(int) pos[0]];
      final long p = pos[1] + OBinaryProtocol.SIZE_SHORT + OBinaryProtocol.SIZE_LONG + OBinaryProtocol.SIZE_BYTE;

      holeSegment.pushPosition(position);

      // MARK DELETED SETTING VERSION TO NEGATIVE NUMBER
      final int version = file.readInt(p);
      file.writeInt(p, (version + 1) * -1);

      updateBoundsAfterDeletion(iPosition);

    } finally {
      releaseExclusiveLock();
    }
  }
162631
def remove(self, position):
        
        if position <= 0:  # at beginning
            return self.remove_first()

        if position >= self.length() - 1:  # at end
            return self.remove_last()

        counter = 0
        last_node = self.head
        current_node = self.head

        while current_node is not None and counter <= position:
            if counter == position:
                last_node.next_node = current_node.next_node  # remove current
                return True

            last_node = current_node
            current_node = current_node.next_node
            counter += 1

        return False
1194238
function destroyMap (map) {
    var el = map.getContainer();
    map.remove();
    document.body.removeChild(el);
  }
868728
def _remove_layer_clicked(self):
        """"""
        layer = self.list_layers_in_map_report.selectedItems()[0]
        origin = layer.data(LAYER_ORIGIN_ROLE)
        if origin == FROM_ANALYSIS['key']:
            key = layer.data(LAYER_PURPOSE_KEY_OR_ID_ROLE)
            parent = layer.data(LAYER_PARENT_ANALYSIS_ROLE)
            parent_item = self.tree.findItems(
                parent, Qt.MatchContains | Qt.MatchRecursive, 0)[0]
            item = QTreeWidgetItem(parent_item, [definition(key)['name']])
            item.setData(0, LAYER_PARENT_ANALYSIS_ROLE, parent)
        else:
            parent_item = self.tree.findItems(
                FROM_CANVAS['name'],
                Qt.MatchContains | Qt.MatchRecursive, 0)[0]
            item = QTreeWidgetItem(parent_item, [layer.text()])
            layer_id = layer.data(LAYER_PURPOSE_KEY_OR_ID_ROLE)
            item.setData(0, LAYER_PURPOSE_KEY_OR_ID_ROLE, layer_id)
        item.setData(0, LAYER_ORIGIN_ROLE, origin)
        index = self.list_layers_in_map_report.indexFromItem(layer)
        self.list_layers_in_map_report.takeItem(index.row())
        self.list_layers_in_map_report.clearSelection()
762222
def remove_location(self, location):
        # type: (str) -> bool
        
        res = self._remove_hdxobject(self.data.get('groups'), location, matchon='name')
        if not res:
            res = self._remove_hdxobject(self.data.get('groups'), location.upper(), matchon='name')
        if not res:
            res = self._remove_hdxobject(self.data.get('groups'), location.lower(), matchon='name')
        return res
871559
private void removeInvalidServices(Map<ServiceKey,Service> map) {
        for (Iterator t = map.entrySet().iterator(); t.hasNext(); ) {
            Map.Entry entry = (Map.Entry)t.next();
            Service s = (Service)entry.getValue();
            if (s.isValid() == false) {
                t.remove();
            }
        }
    }
569511
public V remove (int key)
    {
        Record<V> removed = removeImpl(key, true);
        return (removed == null) ? null : removed.value;
    }
846371
public void remove(String key) {
        String processedKey = processKey(key);
        String orderKey = null;

        // removing key set for all positions
        for (int i = 0; i < this.order.size(); i++) {
            orderKey = this.order.get(i);

            if (orderKey != null && orderKey.equals(processedKey) == true) {
                this.order.remove(i);
            }
        }

        this.types.remove(processedKey);
        this.direction.remove(processedKey);
        this.values.remove(processedKey);
    }
368090
def remove_stale_items(self, stale_cts):
        
        stale_ct_ids = list(stale_cts.keys())
        items = (ContentItem.objects
                 .non_polymorphic()  # very important, or polymorphic skips them on fetching derived data
                 .filter(polymorphic_ctype__in=stale_ct_ids)
                 .order_by('polymorphic_ctype', 'pk')
                 )
        if not items:
            self.stdout.write("No stale items found.")
            return

        if self.dry_run:
            self.stdout.write("The following content items are stale:")
        else:
            self.stdout.write("The following content items were stale:")

        for item in items:
            ct = stale_cts[item.polymorphic_ctype_id]
            self.stdout.write("- #{id} points to removed {app_label}.{model}".format(
                id=item.pk, app_label=ct.app_label, model=ct.model
            ))

            if not self.dry_run:
                try:
                    item.delete()
                except PluginNotFound:
                    Model.delete(item)
687010
static <K, E> void removeFromList(Map<K, List<E>> map, K k, E e)
    {
        List<E> list = map.get(k);
        if (list != null)
        {
            list.remove(e);
            if (list.isEmpty())
            {
                map.remove(k);
            }
        }
    }
847721
public void removeProfile(int position) {
        if (mAccountHeaderBuilder.mProfiles != null && mAccountHeaderBuilder.mProfiles.size() > position) {
            mAccountHeaderBuilder.mProfiles.remove(position);
        }

        mAccountHeaderBuilder.updateHeaderAndList();
    }