Deletes all user media images of the given instance.
545856
def _delete_images(self, instance):
        """"""
        UserMediaImage.objects.filter(
            content_type=ContentType.objects.get_for_model(instance),
            object_id=instance.pk,
            user=instance.user,
        ).delete()
303562
public static mps_image delete(nitro_service client, mps_image resource) throws Exception
	{
		resource.validate("delete");
		return ((mps_image[]) resource.delete_resource(client))[0];
	}
530944
def image_delete(auth=None, **kwargs):
    '''
    
    '''
    cloud = get_operator_cloud(auth)
    kwargs = _clean_kwargs(**kwargs)
    return cloud.delete_image(**kwargs)
743536
public function clear()
    {
        foreach (array_keys($this->instances) as $key) {
            $this->instances[$key] = null;
            unset($this->instances[$key]);
        }

        $this->instances = [];
    }
47437
def delete(request, obj_id=None):
    
    data = request.DELETE or json.loads(request.body)
    guids = data.get('guids').split(',')
    objects = getObjectsFromGuids(guids)
    gallery = Gallery.objects.get(pk=obj_id)

    LOGGER.info('{} removed {} from {}'.format(request.user.email, guids, gallery))

    for o in objects:
        if isinstance(o, Image):
            gallery.images.remove(o)
        elif isinstance(o, Video):
            gallery.videos.remove(o)

    res = Result()

    return JsonResponse(res.asDict())
483589
def clear(self):
        
        all_keys = self._find_keys_raw(settings.THUMBNAIL_KEY_PREFIX)
        if all_keys:
            self._delete_raw(*all_keys)
1189616
public function deleteImageFile()
    {
        if ($this->hasCategory('photo') || $this->hasCategory('thetas')) {
            // Get thumbnail path
            $path = __DIR__."/../../../web/media/cache/thumbnail"
                    .$this->getImage();

            // Delete file if exists
            if (is_file($path)) {
                unlink($path);
            }
        }
    }
342757
public function destroyAll()
    {
        if ($this->newImage)
        {
            $this->destroy($this->newImage);
        }

        if ($this->sourceImage)
        {
            $this->destroy($this->sourceImage);
        }
    }
100137
def _clear(self):
        
        self._plain_image = [" " * self._width for _ in range(self._height)]
        self._colour_map = [[(None, 0, 0) for _ in range(self._width)]
                            for _ in range(self._height)]
11131
public static void deleteInstanceResources( Instance instance )	throws IOException {
		File dir = InstanceHelpers.findInstanceDirectoryOnAgent( instance );
		Utils.deleteFilesRecursively( dir );
	}
260981
def delete_all_renditions(self):
        ''''''
        if self.renditions:
            for r in self.renditions.values():
                default_storage.delete(r)
            self.renditions = {}
1208200
def delete(self, *args, **kwargs):
        
        source_cache = self.get_source_cache()
        # First, delete any related thumbnails.
        self.delete_thumbnails(source_cache)
        # Next, delete the source image.
        super(ThumbnailerFieldFile, self).delete(*args, **kwargs)
        # Finally, delete the source cache entry.
        if source_cache and source_cache.pk is not None:
            source_cache.delete()
1114272
def delete(self):
        
        self.manager.session.delete(self.uri)
        self.manager._metrics_contexts.remove(self)
610642
def delete(self, **kwds):
        
        result = self._client.photo.delete(self, **kwds)
        self._delete_fields()
        return result
1039191
public static function clearAll()
  {
    $names = array_keys(self::$_instances);
    foreach ($names as $name) {
      self::clearInstance($name);
    }
  }
424900
public void destroy() throws SlickException {
		for (int tx=0;tx<xcount;tx++) {
			for (int ty=0;ty<ycount;ty++) {
				Image image = images[tx][ty];
				image.destroy();
			}
		}
	}
937676
public void clearAll() {
        this.auths.clear();
        this.authsByUser.clear();
        File[] auths = this.authStoreDir.listFiles(new AuthFilenameFilter());
        for (int i = 0; i < auths.length; i++) {
            auths[i].delete();
        }
    }