All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.whispersystems.signalservice.api.SignalServiceSenderKeyStore Maven / Gradle / Ivy

There is a newer version: 2.15.3_unofficial_107
Show newest version
package org.whispersystems.signalservice.api;

import org.signal.libsignal.protocol.SignalProtocolAddress;
import org.signal.libsignal.protocol.groups.state.SenderKeyStore;
import org.whispersystems.signalservice.api.push.DistributionId;

import java.util.Collection;
import java.util.Set;

/**
 * And extension of the normal protocol sender key store interface that has additional methods that are
 * needed in the service layer, but not the protocol layer.
 */
public interface SignalServiceSenderKeyStore extends SenderKeyStore {
  /**
   * @return A set of protocol addresses that have previously been sent the sender key data for the provided distributionId.
   */
  Set getSenderKeySharedWith(DistributionId distributionId);

  /**
   * Marks the provided addresses as having been sent the sender key data for the provided distributionId.
   */
  void markSenderKeySharedWith(DistributionId distributionId, Collection addresses);

  /**
   * Marks the provided addresses as not knowing about any distributionIds.
   */
  void clearSenderKeySharedWith(Collection addresses);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy