Object first = collection.iterator ().next (); Asset firstAsset = (Asset) collection.iterator ().next (); ((NewItemIdentificationPG)firstAsset.getItemIdentificationPG()).setItemIdentification ( firstAsset.getItemIdentificationPG ().getItemIdentification () + "_changed"); publishChange (firstAsset); } catch (Exception exc) { error("Could not change asset."); error(exc.getMessage()); exc.printStackTrace(); } finally{ blackboard.closeTransactionDontReset(); }
Asset firstAsset = (Asset) collection.iterator ().next (); ((NewItemIdentificationPG)firstAsset.getItemIdentificationPG()).setItemIdentification ( firstAsset.getItemIdentificationPG ().getItemIdentification () + "_changed"); publishChange (firstAsset); } catch (Exception exc) { error("Could not change asset."); error(exc.getMessage()); exc.printStackTrace(); } finally{ blackboard.closeTransactionDontReset(); }
  void changeAsset () {	try {	  blackboard.openTransaction();	  Collection collection = myAssetCallback.getSubscription ().getCollection();			  Object first = collection.iterator ().next ();	  Asset firstAsset = (Asset) collection.iterator ().next ();	  ((NewItemIdentificationPG)firstAsset.getItemIdentificationPG()).setItemIdentification (																 firstAsset.getItemIdentificationPG ().getItemIdentification () + 																  "_changed");	  publishChange (firstAsset);	} catch (Exception exc) {	  error("Could not change asset.");	  error(exc.getMessage());	  exc.printStackTrace();	}	finally{	  blackboard.closeTransactionDontReset();	}  }