com.sap.ip.me.api.smartsync
Interface SyncBoOutDeltaObserver


Deprecated. avoid using SyncBoOutDelta because it reduces performance of outbound processing.

public interface SyncBoOutDeltaObserver

This interface has to be implemented for any class observing SyncBO outbound delta. SmartSync does not provide any abstract class or concrete class for this interface. It has to specify which SyncBO outbound delta it is notified for by naming the SyncBO types it is obeserving. When processing SyncBO outbound delta data for one of the specified SyncBO types, method sendingOutDeltaReceived is called. this observer is called before sending takes place. It is only used for SyncBo delta to the backend, no delta that is initiated from within the client.

To activate the observer, its instance needs to be registered with SyncBoOutDeltaNotifier.

note
Transaction is not allowed to be used inside callback method sendingSyncBoOutDelta(SyncBoOutDelta), and therefore SmartSyncTransactionManager.beginTransaction() musn't be called inside.

Example:
Not to send a request for a particular syncbo.

  public class MyOutDeltaOberver implements SyncBoOutDeltaObserver {
    //Return the descriptor of the syncbo which the application should observe.
    public SyncBoDescriptor[] observerSyncBoTypes(){
        SyncBoDescriptor[] syncBoArray = new SyncBoDescriptor[1];
        syncBoArray[0]= syncBoDesc;
    }
    //Set the Sync Type
    public void sendingSyncBoOutDelta(SyncBoOutDelta syncoBoOutDelta){
       syncBoOutDelta.setSendType(SyncBoOutDeltaSendType.NO_SEND);
    }
 }
 //Register the observer
 SmartSyncRuntime.getSyncBoOutDeltaNotifier().registerSyncBoOutDeltaObserver(MyOutDeltaOberver);
 

Version:
2.1
Author:
SAP
See Also:
SyncBoOutDeltaNotifier, SyncBoOutDelta

Method Summary
 SyncBoDescriptor[] observeSyncBoTypes()
          Deprecated. Specifies SyncBo descriptors that application needs to observe.
 void sendingSyncBoOutDelta(SyncBoOutDelta syncBoOutDelta)
          Deprecated. Notifies the observer with the outbound data which is designated by application
 

Method Detail

observeSyncBoTypes

public SyncBoDescriptor[] observeSyncBoTypes()
Deprecated. 
Specifies SyncBo descriptors that application needs to observe.

Returns:
SyncBoDescriptor array for observing

sendingSyncBoOutDelta

public void sendingSyncBoOutDelta(SyncBoOutDelta syncBoOutDelta)
Deprecated. 
Notifies the observer with the outbound data which is designated by application

Parameters:
syncBoOutDelta - Description of the Parameter


Copyright © 2005 SAP AG. All Rights Reserved.