Class FileSyncHandler

java.lang.Object
com.usatiuk.dhfsfs.objects.FileSyncHandler
All Implemented Interfaces:
ObjSyncHandler<File,FileDto>

@ApplicationScoped public class FileSyncHandler extends Object implements ObjSyncHandler<File,FileDto>
Handles synchronization of file objects.
  • Constructor Details

    • FileSyncHandler

      public FileSyncHandler()
  • Method Details

    • handleRemoteUpdate

      public void handleRemoteUpdate(PeerId from, JObjectKey key, org.pcollections.PMap<PeerId,Long> receivedChangelog, @Nullable FileDto receivedData)
      Description copied from interface: ObjSyncHandler
      Handles a remote update of an object.
      Specified by:
      handleRemoteUpdate in interface ObjSyncHandler<File,FileDto>
      Parameters:
      from - the ID of the peer that sent the update
      key - the key of the object
      receivedChangelog - the changelog received from the peer
      receivedData - the data received from the peer