Advertisement
Guest User

Untitled

a guest
Apr 25th, 2019
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. MainActivity.java:
  2.  
  3. public class MainActivity extends GooglePlayServiceActivity implements PushCallback, ConnectListener {
  4. ...
  5. Singular.init(this, new SingularConfig("com2ususa_ef7d31a4", "0ad35eca4cda05edd901a1fb892f39b1"));
  6. ...
  7. }
  8.  
  9. Singluar.java:
  10.  
  11. public static void init(Context context, String str, String str2) {
  12. init(context, new SingularConfig(str, str2));
  13. }
  14.  
  15. public static boolean init(Context context, SingularConfig singularConfig) {
  16. try {
  17. singular = SingularInstance.getInstance(context, singularConfig);
  18. saved_application_context = context.getApplicationContext();
  19. } catch (IOException e) {
  20. logger.debug("Failed to init() Singular SDK");
  21. logger.error("init() IOException", e);
  22. singular = null;
  23. } catch (RuntimeException e2) {
  24. reportException(e2);
  25. logger.error("Exception", e2);
  26. }
  27. return isInitialized();
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement