23.1.3.1 Map.prototype.clear() 23.2.3.2 Set.prototype.clear()
519134
function clear() {
        var that = this;
        var state = getInternalState(that);
        var data = state.index;
        var entry = state.first;
        while (entry) {
          entry.removed = true;
          if (entry.previous) entry.previous = entry.previous.next = undefined;
          delete data[entry.index];
          entry = entry.next;
        }
        state.first = state.last = undefined;
        if (DESCRIPTORS) state.size = 0;
        else that.size = 0;
      }
912163
public static <K, V> void clear(Map<K, V> map) {
        if (map != null) {
            map.clear();
        }
    }
204513
function(prop, current) {
                    if (prop in this._data) {
                        // Delete the property from `_data` and the Map
                        // as long as it isn't part of the Map's prototype.
                        delete this._data[prop];
                        if (!(prop in this.constructor.prototype)) {
                            delete this[prop];
                        }
                        // Let others now this property has been removed.
                        this._triggerChange(prop, "remove", undefined, current);

                    }
                }
766196
public void clearAlphaMap() {
		pushTransform();
		GL.glLoadIdentity();
		
		int originalMode = currentDrawingMode;
		setDrawMode(MODE_ALPHA_MAP);
		setColor(new Color(0,0,0,0));
		fillRect(0, 0, screenWidth, screenHeight);
		setColor(currentColor);
		setDrawMode(originalMode);
		
		popTransform();
	}
391416
function() {
            this.objects = [];
            this.map.reset();
            var map = this.map;
            this.map.each(function(val, x, y){
                map.set(x, y, []);
            });
        }
907185
function(map) {

  var Fuzzymap = {};
  var Map = map;
  var PureMap = map;
  var LastValue = null;

  if(!_.isArray(map))
    Map = [Map]

  Fuzzymap.Map = function() { return PureMap; };
  Fuzzymap.last = function() { return LastValue; };
  Fuzzymap.keys = function() {
    return _.chain(Map)
      .compact()
      .map(function(mapDefinition) {
        return _.keys(mapDefinition);
      })
      .flatten()
      .uniq()
      .value();
  }

  Fuzzymap.map = function(item) {
    LastValue = item;
    
    if(_.isObject(item))
      testObject(item);
    else
      testItem(item);

    return Fuzzymap.last();
  };

  Fuzzymap.extract = function(item) {
    LastValue = item;

    if(!_.isObject)
      return item;

    return extractObject(item);
  };

  var extractObject = function(param) {
    var result = {};
    var defaults = {};
    _.each(Map, function(MapGroup) {
      _.each(_.keys(MapGroup), function(key) {
        if(!defaults.hasOwnProperty(key))
          defaults[key] = null;
      });
    });

    _.each(_.keys(param), function(key) {
      var mappedKey = testItem(key);
      if(defaults.hasOwnProperty(mappedKey))
        defaults[mappedKey] = param[key];
    });

    return defaults;
  };

  var testObject = function(param) {
    var result = {};
    _.each(_.keys(param), function(key) {
      var mappedKey = testItem(key);
      result[mappedKey] = param[key];
    });
    LastValue = result;
    
    return result;
  };

  var testItem = function(item) {
    LastValue = item;
    _.find(Map, function(MapGroup) {
      return testGroup(item, MapGroup) !== false;
    });

    return Fuzzymap.last();
  };
    
  var testGroup = function(item, MapGroup) {
    if(nil(MapGroup))
      MapGroup = {};

    var mapped = _.find(_.keys(MapGroup), function(mapString) {
      var regexes = MapGroup[mapString];

      if(!_.isArray(regexes))
        regexes = [regexes];

      var regex = _.find(regexes, function(regex) {
        return nil(item.match(regex)) === false;
      });
      
      return nil(regex) === false;
    });

    if(!nil(mapped))
      LastValue = mapped;
    
    return nil(mapped) === false;

  };

  return Fuzzymap;
}
161
public void clearKSMap() {
        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
            Tr.debug(tc, "Clearing keystore maps");
        synchronized (keyStoreMap) {
            keyStoreMap.clear();
        }
    }
35549
private Object retainAll(Schema schema, MarkSet markSet, ProtoType type, Object o) {
    if (!markSet.contains(type)) {
      return null; // Prune this type.

    } else if (o instanceof Map) {
      ImmutableMap.Builder<ProtoMember, Object> builder = ImmutableMap.builder();
      for (Map.Entry<?, ?> entry : ((Map<?, ?>) o).entrySet()) {
        ProtoMember protoMember = (ProtoMember) entry.getKey();
        if (!markSet.contains(protoMember)) continue; // Prune this field.
        Field field = schema.getField(protoMember);
        Object retainedValue = retainAll(schema, markSet, field.type(), entry.getValue());
        if (retainedValue != null) {
          builder.put(protoMember, retainedValue); // This retained field is non-empty.
        }
      }
      ImmutableMap<ProtoMember, Object> map = builder.build();
      return !map.isEmpty() ? map : null;

    } else if (o instanceof List) {
      ImmutableList.Builder<Object> builder = ImmutableList.builder();
      for (Object value : ((List) o)) {
        Object retainedValue = retainAll(schema, markSet, type, value);
        if (retainedValue != null) {
          builder.add(retainedValue); // This retained value is non-empty.
        }
      }
      ImmutableList<Object> list = builder.build();
      return !list.isEmpty() ? list : null;

    } else {
      return o;
    }
  }
321075
function() {

        //clear out layers info and unregister their events
        this.clearLayersArray("base");
        this.clearLayersArray("data");

        this.map.events.un({
            buttonclick: this.onButtonClick,
            addlayer: this.redraw,
            changelayer: this.redraw,
            removelayer: this.redraw,
            changebaselayer: this.redraw,
            scope: this
        });
        this.events.unregister("buttonclick", this, this.onButtonClick);

        OpenLayers.Control.prototype.destroy.apply(this, arguments);
    }
832247
@Override
  public void clear() {
    if (head < tail) {
      Arrays.fill(buffer, head, tail, Intrinsics.empty());
    } else {
      Arrays.fill(buffer, 0, tail, Intrinsics.empty());
      Arrays.fill(buffer, head, buffer.length, Intrinsics.empty());
    }
    this.head = tail = 0;
  }
467218
private void clear(Object caller, int version) {
        assert mutation_in_progress(caller, version);
        _buf_limit = 0;
        for (int ii=0; ii<_blocks.size(); ii++) {
            _blocks.get(ii).clearBlock();
            // _blocks.get(ii)._idx = -1; this is done in clearBlock()
        }
        bbBlock first = _blocks.get(0);
        first._idx = 0;                        // cas: 26 dec 2008
        first._offset = 0;
        first._limit = 0;
        _next_block_position = 1;
        return;
    }
797056
function(map) {
        if (this.pane && this.pane.parentNode) {
            this.pane.parentNode.removeChild(this.pane);
        }
        OpenLayers.Layer.prototype.removeMap.apply(this, arguments);
    }
568813
@Override
    public Set keySet() {
        if (keySet != null) {
            return keySet;
        }
        keySet = new AbstractSet() {
            @Override
            public Iterator iterator() {
                return new KeyIterator();
            }            @Override
            public int size() {
                return size;
            }



            @Override
            public boolean contains(final Object o) {
                return containsKey(o);
            }


            @Override
            public boolean remove(final Object o) {
                final Object r = ReferenceMap.this.remove(o);
                return r != null;
            }

            @Override
            public void clear() {
                ReferenceMap.this.clear();
            }

        };
        return keySet;
    }
426044
@Override
	public void clear() {
		// This makes the formula false
		if (booleanTerms != null) {
			booleanTerms.clear();
		} else {
			booleanTerms = new HashSet<BooleanTerm>();
		}
		isSimplified = true;
	}
996755
function( map ){
      var empty = true;

      if( map != null ){
        for(var i in map){
          empty = false;
          break;
        }
      }

      return empty;
    }
705841
@Override
    public void clear()
    {
        eagerlyLoadDataCollection();
        if (getDataCollection() != null && !(getDataCollection() instanceof ProxyCollection))
        {
            ((Map)getDataCollection()).clear();
        }
    }
1321514
public void clear() {
		streamNodes = new HashMap<>();
		virtualSelectNodes = new HashMap<>();
		virtualSideOutputNodes = new HashMap<>();
		virtualPartitionNodes = new HashMap<>();
		vertexIDtoBrokerID = new HashMap<>();
		vertexIDtoLoopTimeout  = new HashMap<>();
		iterationSourceSinkPairs = new HashSet<>();
		sources = new HashSet<>();
		sinks = new HashSet<>();
	}