/**
  * Sets the application attribute using the name passed to the constructor on a batch feed.
  *
  * @param batchFeed
  */
 @SuppressWarnings("unchecked")
 private void addApplicationAttribute(IFeed iFeed) {
   if (!(iFeed instanceof BaseFeed)) {
     throw new IllegalArgumentException("Unexpected feed type: " + iFeed);
   }
   BaseFeed<?, ?> batchFeed = (BaseFeed<?, ?>) iFeed;
   BatchOperationType defaultType = BatchUtils.getBatchOperationType(batchFeed);
   if (defaultType == null) {
     defaultType = BatchOperationType.INSERT;
   }
   List<? extends BaseEntry> entries = batchFeed.getEntries();
   for (BaseEntry<?> entry : entries) {
     BatchOperationType type = BatchUtils.getBatchOperationType(entry);
     if (type == null) {
       type = defaultType;
     }
     if (type == BatchOperationType.INSERT || type == BatchOperationType.UPDATE) {
       addApplicationAttribute(entry);
     }
   }
 }