コード例 #1
0
  @Override
  public long saveTrigger(SPFTrigger trigger, String token, SPFError err) {
    Utils.logCall(TAG, "saveTrigger", trigger, token, err);

    AppAuth appAuth;
    try {
      appAuth = getAppAuth(token, err);
    } catch (Exception e) {
      return -1;
    }
    return getSPFNotificationManager().saveTrigger(trigger, appAuth.getAppIdentifier());
  }
コード例 #2
0
  @Override
  public boolean deleteTrigger(long triggerId, String token, SPFError err) {
    Utils.logCall(TAG, "deleteTrigger", triggerId, token, err);

    AppAuth appAuth;
    try {
      appAuth = getAppAuth(token, err);
    } catch (Exception e) {
      return false;
    }
    return getSPFNotificationManager().deleteTrigger(triggerId, appAuth.getAppIdentifier());
  }
コード例 #3
0
  @Override
  public List<SPFTrigger> listTrigger(String token, SPFError err) {
    Utils.logCall(TAG, "listTrigger", token, err);

    AppAuth appAuth;
    try {
      appAuth = getAppAuth(token, err);
    } catch (Exception e) {
      return new ArrayList<SPFTrigger>(0);
    }
    return getSPFNotificationManager().listTriggers(appAuth.getAppIdentifier());
  }