RouteDatabase.smali 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. .class public final Lokhttp3/internal/connection/RouteDatabase;
  2. .super Ljava/lang/Object;
  3. .source ""
  4. # instance fields
  5. .field private final failedRoutes:Ljava/util/Set;
  6. .annotation system Ldalvik/annotation/Signature;
  7. value = {
  8. "Ljava/util/Set<",
  9. "Lokhttp3/Route;",
  10. ">;"
  11. }
  12. .end annotation
  13. .end field
  14. # direct methods
  15. .method public constructor <init>()V
  16. .locals 1
  17. invoke-direct {p0}, Ljava/lang/Object;-><init>()V
  18. new-instance v0, Ljava/util/LinkedHashSet;
  19. invoke-direct {v0}, Ljava/util/LinkedHashSet;-><init>()V
  20. iput-object v0, p0, Lokhttp3/internal/connection/RouteDatabase;->failedRoutes:Ljava/util/Set;
  21. return-void
  22. .end method
  23. # virtual methods
  24. .method public declared-synchronized connected(Lokhttp3/Route;)V
  25. .locals 1
  26. monitor-enter p0
  27. :try_start_0
  28. iget-object v0, p0, Lokhttp3/internal/connection/RouteDatabase;->failedRoutes:Ljava/util/Set;
  29. invoke-interface {v0, p1}, Ljava/util/Set;->remove(Ljava/lang/Object;)Z
  30. :try_end_0
  31. .catchall {:try_start_0 .. :try_end_0} :catchall_0
  32. monitor-exit p0
  33. return-void
  34. :catchall_0
  35. move-exception p1
  36. monitor-exit p0
  37. throw p1
  38. .end method
  39. .method public declared-synchronized failed(Lokhttp3/Route;)V
  40. .locals 1
  41. monitor-enter p0
  42. :try_start_0
  43. iget-object v0, p0, Lokhttp3/internal/connection/RouteDatabase;->failedRoutes:Ljava/util/Set;
  44. invoke-interface {v0, p1}, Ljava/util/Set;->add(Ljava/lang/Object;)Z
  45. :try_end_0
  46. .catchall {:try_start_0 .. :try_end_0} :catchall_0
  47. monitor-exit p0
  48. return-void
  49. :catchall_0
  50. move-exception p1
  51. monitor-exit p0
  52. throw p1
  53. .end method
  54. .method public declared-synchronized shouldPostpone(Lokhttp3/Route;)Z
  55. .locals 1
  56. monitor-enter p0
  57. :try_start_0
  58. iget-object v0, p0, Lokhttp3/internal/connection/RouteDatabase;->failedRoutes:Ljava/util/Set;
  59. invoke-interface {v0, p1}, Ljava/util/Set;->contains(Ljava/lang/Object;)Z
  60. move-result p1
  61. :try_end_0
  62. .catchall {:try_start_0 .. :try_end_0} :catchall_0
  63. monitor-exit p0
  64. return p1
  65. :catchall_0
  66. move-exception p1
  67. monitor-exit p0
  68. throw p1
  69. .end method