當前位置: 首頁>>代碼示例>>Java>>正文


Java MasterSecretRequirement類代碼示例

本文整理匯總了Java中org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement的典型用法代碼示例。如果您正苦於以下問題:Java MasterSecretRequirement類的具體用法?Java MasterSecretRequirement怎麽用?Java MasterSecretRequirement使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


MasterSecretRequirement類屬於org.thoughtcrime.securesms.jobs.requirements包,在下文中一共展示了MasterSecretRequirement類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: constructParameters

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
protected static JobParameters constructParameters(Context context, String destination) {
  JobParameters.Builder builder = JobParameters.newBuilder();
  builder.withPersistence();
  builder.withGroupId(destination);
  builder.withRequirement(new MasterSecretRequirement(context));
  builder.withRequirement(new NetworkRequirement(context));
  builder.withRetryCount(5);

  return builder.create();
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:11,代碼來源:PushSendJob.java

示例2: MultiDeviceBlockedUpdateJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public MultiDeviceBlockedUpdateJob(Context context) {
  super(context, JobParameters.newBuilder()
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withGroupId(MultiDeviceBlockedUpdateJob.class.getSimpleName())
                              .withPersistence()
                              .create());
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:9,代碼來源:MultiDeviceBlockedUpdateJob.java

示例3: MultiDeviceGroupUpdateJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public MultiDeviceGroupUpdateJob(Context context) {
  super(context, JobParameters.newBuilder()
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withGroupId(MultiDeviceGroupUpdateJob.class.getSimpleName())
                              .withPersistence()
                              .create());
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:9,代碼來源:MultiDeviceGroupUpdateJob.java

示例4: SmsSentJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public SmsSentJob(Context context, long messageId, String action, int result) {
  super(context, JobParameters.newBuilder()
                              .withPersistence()
                              .withRequirement(new MasterSecretRequirement(context))
                              .create());

  this.messageId = messageId;
  this.action    = action;
  this.result    = result;
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:11,代碼來源:SmsSentJob.java

示例5: CreateSignedPreKeyJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public CreateSignedPreKeyJob(Context context) {
  super(context, JobParameters.newBuilder()
                              .withPersistence()
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withGroupId(CreateSignedPreKeyJob.class.getSimpleName())
                              .create());
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:9,代碼來源:CreateSignedPreKeyJob.java

示例6: MultiDeviceContactUpdateJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public MultiDeviceContactUpdateJob(Context context, long recipientId) {
  super(context, JobParameters.newBuilder()
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withGroupId(MultiDeviceContactUpdateJob.class.getSimpleName())
                              .withPersistence()
                              .create());

  this.recipientId = recipientId;
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:11,代碼來源:MultiDeviceContactUpdateJob.java

示例7: RefreshPreKeysJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public RefreshPreKeysJob(Context context) {
  super(context, JobParameters.newBuilder()
                              .withGroupId(RefreshPreKeysJob.class.getSimpleName())
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withRetryCount(5)
                              .create());
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:9,代碼來源:RefreshPreKeysJob.java

示例8: constructParameters

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
private static JobParameters constructParameters(Context context, String name) {
  JobParameters.Builder builder = JobParameters.newBuilder()
                                               .withPersistence()
                                               .withRequirement(new MasterSecretRequirement(context))
                                               .withRetryCount(15)
                                               .withGroupId(name);

  if (TextSecurePreferences.isWifiSmsEnabled(context)) {
    builder.withRequirement(new NetworkOrServiceRequirement(context));
  } else {
    builder.withRequirement(new ServiceRequirement(context));
  }

  return builder.create();
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:16,代碼來源:SmsSendJob.java

示例9: PushGroupSendJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public PushGroupSendJob(Context context, long messageId, String destination, long filterRecipientId,
                        Recipients destRecipients) {
  super(context, JobParameters.newBuilder()
                              .withPersistence()
                              .withGroupId(destination)
                              .withRequirement(new MasterSecretRequirement(context))
                              .withRequirement(new NetworkRequirement(context))
                              .withRetryCount(5)
                              .create());

  this.messageId         = messageId;
  this.filterRecipientId = filterRecipientId;
  this.destRecipients    = destRecipients;
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:15,代碼來源:PushGroupSendJob.java

示例10: MmsSendJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public MmsSendJob(Context context, long messageId) {
  super(context, JobParameters.newBuilder()
                              .withGroupId("mms-operation")
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withPersistence()
                              .create());

  this.messageId = messageId;
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:11,代碼來源:MmsSendJob.java

示例11: AttachmentDownloadJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public AttachmentDownloadJob(Context context, long messageId, AttachmentId attachmentId) {
  super(context, JobParameters.newBuilder()
                              .withGroupId(AttachmentDownloadJob.class.getCanonicalName())
                              .withRequirement(new MasterSecretRequirement(context))
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MediaNetworkRequirement(context, messageId, attachmentId))
                              .withPersistence()
                              .create());

  this.messageId    = messageId;
  this.partRowId    = attachmentId.getRowId();
  this.partUniqueId = attachmentId.getUniqueId();
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:14,代碼來源:AttachmentDownloadJob.java

示例12: RotateSignedPreKeyJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public RotateSignedPreKeyJob(Context context) {
  super(context, JobParameters.newBuilder()
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withRetryCount(5)
                              .create());
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:8,代碼來源:RotateSignedPreKeyJob.java

示例13: MmsDownloadJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public MmsDownloadJob(Context context, long messageId, long threadId, boolean automatic) {
  super(context, JobParameters.newBuilder()
                              .withPersistence()
                              .withRequirement(new MasterSecretRequirement(context))
                              .withRequirement(new NetworkRequirement(context))
                              .withGroupId("mms-operation")
                              .withWakeLock(true, 30, TimeUnit.SECONDS)
                              .create());

  this.messageId = messageId;
  this.threadId  = threadId;
  this.automatic = automatic;
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:14,代碼來源:MmsDownloadJob.java

示例14: CleanPreKeysJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public CleanPreKeysJob(Context context) {
  super(context, JobParameters.newBuilder()
                              .withGroupId(CleanPreKeysJob.class.getSimpleName())
                              .withRequirement(new MasterSecretRequirement(context))
                              .withRetryCount(5)
                              .create());
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:8,代碼來源:CleanPreKeysJob.java

示例15: MultiDeviceReadUpdateJob

import org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement; //導入依賴的package包/類
public MultiDeviceReadUpdateJob(Context context, List<SyncMessageId> messageIds) {
  super(context, JobParameters.newBuilder()
                              .withRequirement(new NetworkRequirement(context))
                              .withRequirement(new MasterSecretRequirement(context))
                              .withPersistence()
                              .create());

  this.messageIds = new LinkedList<>();

  for (SyncMessageId messageId : messageIds) {
    this.messageIds.add(new SerializableSyncMessageId(messageId.getAddress(), messageId.getTimetamp()));
  }
}
 
開發者ID:XecureIT,項目名稱:PeSanKita-android,代碼行數:14,代碼來源:MultiDeviceReadUpdateJob.java


注:本文中的org.thoughtcrime.securesms.jobs.requirements.MasterSecretRequirement類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。