Delete activities referring to given entity model instance

 @param model [Object] Model instance
331290
def delete_activities_for_entity_model(model)
      Activr.registry.activity_entities_for_model(model.class).each do |entity_name|
        self.driver.delete_activities(:entities => { entity_name => model.id })
      end
    end
653781
private void deleteRemainingRelationsFromMatrix(IMappingElement<INode> e) {
        //deletes all the relations in the column
        for (INode i : defautlMappings.getSourceContext().getNodesList()) {
            if (i != e.getSource()) {
                defautlMappings.setRelation(i, e.getTarget(), IMappingElement.IDK);
            }
        }

        //deletes all the relations in the row
        for (INode j : defautlMappings.getTargetContext().getNodesList()) {
            if (j != e.getTarget()) {
                defautlMappings.setRelation(e.getSource(), j, IMappingElement.IDK);
            }
        }
    }
841640
def delete(cls, **kwargs):
        '''
        
        '''
        q = cls._get_instance(**kwargs)
        if q:
            _action_and_commit(q, session.delete)
275452
@Override
    public void delete(Object entity, Object pKey)
    {
        s = getStatelessSession();
        Transaction tx = null;
        tx = onBegin();
        s.delete(entity);
        onCommit(tx);

        EntityMetadata metadata = KunderaMetadataManager.getEntityMetadata(kunderaMetadata, entity.getClass());
        MetamodelImpl metamodel = (MetamodelImpl) KunderaMetadataManager.getMetamodel(kunderaMetadata,
                metadata.getPersistenceUnit());
        if (!MetadataUtils.useSecondryIndex(getClientMetadata()))
        {
            getIndexManager().remove(metadata, entity, pKey);
        }
    }
753966
def delete(self,storagemodel):
        
            
        modeldefinition = self.getmodeldefinition(storagemodel, True)

        pk = storagemodel.getPartitionKey()
        rk = storagemodel.getRowKey()

        try:
            modeldefinition['tableservice'].delete_entity(modeldefinition['tablename'], pk, rk)
            storagemodel._exists = False

        except AzureMissingResourceHttpError as e:
            log.debug('can not delete table entity:  Table {}, PartitionKey {}, RowKey {} because {!s}'.format(modeldefinition['tablename'], pk, rk, e))

        finally:
            return storagemodel
725144
def remove(self, resource, **kwargs):
        
        log.info(
            "Removing {} '{}'...".format(self._model_name, resource.name))
        resource.remove(**kwargs)
        self._ids.remove(resource.id)
610769
function (model, options) {
        if (this === model.collection) delete model.collection;
        this._deIndex(model);
        if (model.off) model.off('all', this._onModelEvent, this);
    }
937286
def remove_core_element(self, model):
        
        assert model.data_flow.parent is self.model.state or model.data_flow.parent is self.model.parent.state
        gui_helper_state_machine.delete_core_element_of_model(model)
112538
public function deleting($model)
    {
        foreach ($this->relations as $relation) {
            if ($model->{$relation}()->count() > 0) {
                // Returning false from an Eloquent event listener will cancel the operation.
                return false;
            }
        }
    }
191163
@SuppressWarnings("unused") // called through reflection by RequestServer
  public ModelsV3 delete(int version, ModelsV3 s) {
    Model model = getFromDKV("key", s.model_id.key());
    model.delete();             // lock & remove
    return s;
  }
758386
def _delete(self, *criterion):
        
        with self.flushing():
            count = self._query(*criterion).delete()
        if count == 0:
            raise ModelNotFoundError
        return True
902516
def destroy
      m = model.find(user_scoped.find(params[:id]).id)
      @record_saved = m     # copy for possible later use
      m.destroy

      prepare_list
      @record = model.new
      @flash_notice = t('delete_ok')
    end
1240908
function( model ) {
			model.unbind( 'destroy', this.unregister );
			var coll = this.getCollection( model );
			coll && coll.remove( model );
		}
1283065
def delete(self, **kwargs):
        """"""
        self.inflate()
        for model in self._models:
            model.delete(**kwargs)
        return
1354349
public static function deleteModel($model)
    {
        foreach(AnnotationManager::getPropertiesAnnotations(BeanFactory::getObjectClass($model), RelationBase::class) as $propertyName => $annotations)
        {
            if(null === $model[$propertyName])
            {
                continue;
            }
            $annotation = $annotations[0];
            Delete::parse($model, $propertyName, $annotation);
        }
    }
579147
public function deleting(Model $model)
    {
        $model->deleted_by = $this->guard->check() ? $this->guard->user()->getId() : null;
    }
1186126
public function delete()
    {
        if ($this->isNewRecord()) {
            throw new DeleteModelException("New models can't be deleted.");
        }

        $this->beforeDelete();
        $this->raiseEvent("BeforeDelete");

        $this->Deleted = true;
        $this->save();

        $this->afterDelete();
        $this->raiseEvent("AfterDelete");
    }