DeleteScope.
        [Preview API]
        :param str scope_id:
8248
def delete_scope(self, scope_id):
        
        route_values = {}
        if scope_id is not None:
            route_values['scopeId'] = self._serialize.url('scope_id', scope_id, 'str')
        self._send(http_method='DELETE',
                   location_id='4e11e2bf-1e79-4eb5-8f34-a6337bd0de38',
                   version='5.0-preview.2',
                   route_values=route_values)
1244996
def with_exclusive_scope(method_scoping = {}, &block)
      if method_scoping.values.any? { |e| e.is_a?(ActiveRecord::Relation) }
        raise ArgumentError, <<-MSG
New finder API can not be used with_exclusive_scope. You can either call unscoped to get an anonymous scope not bound to the default_scope:

User.unscoped.where(:active => true)

Or call unscoped with a block:

User.unscoped do
User.where(:active => true).all
end

MSG
      end
      with_scope(method_scoping, :overwrite, &block)
    end
571710
def view_delete(self, id, **kwargs):
        ""
        api_path = "/api/v2/views/{id}.json"
        api_path = api_path.format(id=id)
        return self.call(api_path, method="DELETE", **kwargs)
102813
def delete_view(self, request, object_id, extra_context=None):
        """"""
        if not extra_context:
            extra_context = {}
        extra_context['is_popup'] = request.REQUEST.get('_popup', 0)
        return super(EnhancedAdminMixin, self).delete_view(request, object_id, extra_context)
167878
@Override
    public void deleteScope(final String scopeName, final SecurityContext securityContext,
            final AsyncResponse asyncResponse) {
        long traceId = LoggerHelpers.traceEnter(log, "deleteScope");

        try {
            restAuthHelper.authenticateAuthorize(getAuthorizationHeader(),
                    AuthResourceRepresentation.ofScopes(), READ_UPDATE);
        } catch (AuthException e) {
            log.warn("Delete scope for {} failed due to authentication failure.", scopeName);
            asyncResponse.resume(Response.status(Status.fromStatusCode(e.getResponseCode())).build());
            LoggerHelpers.traceLeave(log, "createStream", traceId);
            return;
        }

        controllerService.deleteScope(scopeName).thenApply(scopeStatus -> {
            if (scopeStatus.getStatus() == DeleteScopeStatus.Status.SUCCESS) {
                log.info("Successfully deleted scope: {}", scopeName);
                return Response.status(Status.NO_CONTENT).build();
            } else if (scopeStatus.getStatus() == DeleteScopeStatus.Status.SCOPE_NOT_FOUND) {
                log.warn("Scope: {} not found", scopeName);
                return Response.status(Status.NOT_FOUND).build();
            } else if (scopeStatus.getStatus() == DeleteScopeStatus.Status.SCOPE_NOT_EMPTY) {
                log.warn("Cannot delete scope: {} with non-empty streams", scopeName);
                return Response.status(Status.PRECONDITION_FAILED).build();
            } else {
                log.warn("deleteScope for {} failed", scopeName);
                return Response.status(Status.INTERNAL_SERVER_ERROR).build();
            }
        }).exceptionally(exception -> {
            log.warn("deleteScope for {} failed with exception: {}", scopeName, exception);
            return Response.status(Status.INTERNAL_SERVER_ERROR).build();
        }).thenApply(asyncResponse::resume)
        .thenAccept(x -> LoggerHelpers.traceLeave(log, "deleteScope", traceId));
    }
458092
def _cleanup_channel(self, channel_id):
        
        with self.lock:
            if channel_id not in self._channels:
                return
            del self._channels[channel_id]
191973
def delete_event_view(request, id):
    
    event = get_object_or_404(Event, id=id)
    if not request.user.has_admin_permission('events'):
        raise exceptions.PermissionDenied

    if request.method == "POST":
        try:
            event.delete()
            messages.success(request, "Successfully deleted event.")
        except Event.DoesNotExist:
            pass

        return redirect("events")
    else:
        return render(request, "events/delete.html", {"event": event})
422088
function(scope) {

		var index = this._debug_all_scopes.indexOf(scope);
		if (index == -1) Lava.t();
		this._debug_all_scopes.splice(index, 1);

	}
407057
def delete(id)
      unless Debugger.started? && Debugger.remove_breakpoint(id)
        raise ArgumentError, "No breakpoint ##{id}"
      end
      Pry.processor.debugging = false if to_a.empty?
    end
1047547
def macro_delete(self, id, **kwargs):
        ""
        api_path = "/api/v2/macros/{id}.json"
        api_path = api_path.format(id=id)
        return self.call(api_path, method="DELETE", **kwargs)
1082375
def deprovision(self, instance_id: str, details: DeprovisionDetails, async_allowed: bool) -> DeprovisionServiceSpec:
        
        
        # Find the instance
        instance = self._backend.find(instance_id)
        if not instance.isProvisioned():
            # the instance does not exist
            raise ErrInstanceDoesNotExist()
        
        return self._backend.delete(instance)
838785
function (id) {
            var scope = this._scopes[id];
            if (scope) {
                _.pull(this._defaults.scopeOrder, id);
                scope.off(".prefsys");
                this.trigger(SCOPEORDER_CHANGE, {
                    id: id,
                    action: "removed"
                });
                this._triggerChange({
                    ids: scope.getKeys()
                });
            }
        }
172229
public static int getScopeId(String scope) throws JspTagException {
		if(scope==null || PAGE.equals(scope)) return PageContext.PAGE_SCOPE;
		else if(REQUEST.equals(scope)) return PageContext.REQUEST_SCOPE;
		else if(SESSION.equals(scope)) return PageContext.SESSION_SCOPE;
		else if(APPLICATION.equals(scope)) return PageContext.APPLICATION_SCOPE;
		else throw new LocalizedJspTagException(ApplicationResources.accessor, "Scope.scope.invalid", scope);
	}
183234
def delete_script(self, script_id):
        
        res = yield from self._pigpio_aio_command(_PI_CMD_PROCD, script_id, 0)
        return _u2i(res)
871374
def nps_survey_preview(self, id, locale=None, **kwargs):
        ""
        api_path = "/api/v2/nps/surveys/{id}/preview"
        api_path = api_path.format(id=id)
        api_query = {}
        if "query" in kwargs.keys():
            api_query.update(kwargs["query"])
            del kwargs["query"]
        if locale:
            api_query.update({
                "locale": locale,
            })
        return self.call(api_path, query=api_query, **kwargs)
992817
public void removeChildScope(IBasicScope scope) {
        log.debug("removeChildScope: {}", scope);
        if (children.containsKey(scope)) {
            // remove from parent
            children.remove(scope);
            if (scope instanceof Scope) {
                unregisterJMX();
            }
        }
    }
836236
def compare(self, previous_scopes):
        
        for scope in self.scopes:
            if scope not in previous_scopes:
                raise OAuthInvalidError(
                    error="invalid_scope",
                    explanation="Invalid scope parameter in request")

        return True