code: private void deleteObject(final App app, final Object obj) throws FrameworkException {
  
  		if (obj instanceof NodeInterface) {
  
  			app.delete((NodeInterface)obj);
  		}
  
  		if (obj instanceof RelationshipInterface) {
  
  			app.delete((RelationshipInterface)obj);
  		}
  
  		if (obj instanceof Iterable) {
  
  			if (batched) {
  
  				final Iterable iterable = (Iterable)obj;
  				final Iterator iterator = iterable.iterator();
  				int count               = 0;
  
  				while (iterator.hasNext()) {
  
  					try (final Tx tx = app.tx()) {
  
  						while (iterator.hasNext()) {
  
  							deleteObject(app, iterator.next());
  
  							if ((++count % batchSize) == 0) {
  								break;
  							}
  						}
  
  						tx.success();
  					}
  
  					logger.debug("Committing batch after {} objects", count);
  
  					// reset count
  					count = 0;
  				}
  
  
  			} else {
  
  				for (final Object o : (Iterable)obj) {
  
  					deleteObject(app, o);
  				}
  			}
  		}
  	}
docs: ----- private methods -----