code: function(event) {
          var feature = event.feature;
          if(feature.state === OpenLayers.State.INSERT ||
             feature.state === OpenLayers.State.UPDATE ||
             feature.state === OpenLayers.State.DELETE) {
              this.save([event.feature]);
          }
      }
docs: Method: triggerSave
  Registered as a listener.  Calls save if a feature has insert, update,
  or delete state.
  
  Parameters:
  event - {Object} The event this function is listening for.