- Imported from https://github.com/supermegamestre/Project-Real-Resurrection-3 - APKTool decompilation (Smali bytecode) for modding and rebuilding APK - Supports both 32-bit (armeabi-v7a) and 64-bit (arm64-v8a) architectures - Includes full Smali source, resources, and native libraries - Ready to rebuild APK after modifications with apktool b command - Added comprehensive README-apktool.md with modding guide This branch complements the JADX branches: - Use JADX (main/discord-community) to UNDERSTAND code (readable Java) - Use APKTool (this branch) to MODIFY and REBUILD APK (editable Smali) Total: 44,417 files, 538.51 MB Smali source code
247 lines
7.9 KiB
Smali
247 lines
7.9 KiB
Smali
.class public Lcom/helpshift/migrator/MigrationFailureLogProvider;
|
|
.super Ljava/lang/Object;
|
|
.source "SourceFile"
|
|
|
|
|
|
# static fields
|
|
.field public static final inProgress:Ljava/util/concurrent/atomic/AtomicBoolean;
|
|
|
|
|
|
# instance fields
|
|
.field public final device:Lcom/helpshift/platform/Device;
|
|
|
|
.field public final hsThreadingService:Lcom/helpshift/concurrency/HSThreadingService;
|
|
|
|
.field public final httpTransport:Lcom/helpshift/network/HTTPTransport;
|
|
|
|
.field public final persistentStorage:Lcom/helpshift/storage/HSPersistentStorage;
|
|
|
|
.field public final preferences:Landroid/content/SharedPreferences;
|
|
|
|
|
|
# direct methods
|
|
.method static constructor <clinit>()V
|
|
.locals 2
|
|
|
|
.line 55
|
|
new-instance v0, Ljava/util/concurrent/atomic/AtomicBoolean;
|
|
|
|
const/4 v1, 0x0
|
|
|
|
invoke-direct {v0, v1}, Ljava/util/concurrent/atomic/AtomicBoolean;-><init>(Z)V
|
|
|
|
sput-object v0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->inProgress:Ljava/util/concurrent/atomic/AtomicBoolean;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public constructor <init>(Landroid/content/Context;Lcom/helpshift/network/HTTPTransport;Lcom/helpshift/storage/HSPersistentStorage;Lcom/helpshift/platform/Device;Lcom/helpshift/concurrency/HSThreadingService;)V
|
|
.locals 2
|
|
|
|
.line 60
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
const-string v0, "__hs_migration_prefs"
|
|
|
|
const/4 v1, 0x0
|
|
|
|
.line 61
|
|
invoke-virtual {p1, v0, v1}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;
|
|
|
|
move-result-object p1
|
|
|
|
iput-object p1, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->preferences:Landroid/content/SharedPreferences;
|
|
|
|
iput-object p2, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->httpTransport:Lcom/helpshift/network/HTTPTransport;
|
|
|
|
iput-object p3, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->persistentStorage:Lcom/helpshift/storage/HSPersistentStorage;
|
|
|
|
iput-object p4, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->device:Lcom/helpshift/platform/Device;
|
|
|
|
iput-object p5, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->hsThreadingService:Lcom/helpshift/concurrency/HSThreadingService;
|
|
|
|
return-void
|
|
.end method
|
|
|
|
.method public static synthetic access$000()Ljava/util/concurrent/atomic/AtomicBoolean;
|
|
.locals 1
|
|
|
|
sget-object v0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->inProgress:Ljava/util/concurrent/atomic/AtomicBoolean;
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public static synthetic access$100(Lcom/helpshift/migrator/MigrationFailureLogProvider;)Landroid/content/SharedPreferences;
|
|
.locals 0
|
|
|
|
.line 45
|
|
iget-object p0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->preferences:Landroid/content/SharedPreferences;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static synthetic access$200(Lcom/helpshift/migrator/MigrationFailureLogProvider;)Lcom/helpshift/platform/Device;
|
|
.locals 0
|
|
|
|
.line 45
|
|
iget-object p0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->device:Lcom/helpshift/platform/Device;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static synthetic access$300(Lcom/helpshift/migrator/MigrationFailureLogProvider;)Lcom/helpshift/storage/HSPersistentStorage;
|
|
.locals 0
|
|
|
|
.line 45
|
|
iget-object p0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->persistentStorage:Lcom/helpshift/storage/HSPersistentStorage;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static synthetic access$400(Lcom/helpshift/migrator/MigrationFailureLogProvider;Ljava/lang/String;Ljava/lang/String;)Lorg/json/JSONObject;
|
|
.locals 0
|
|
|
|
.line 45
|
|
invoke-virtual {p0, p1, p2}, Lcom/helpshift/migrator/MigrationFailureLogProvider;->jsonify(Ljava/lang/String;Ljava/lang/String;)Lorg/json/JSONObject;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static synthetic access$500(Lcom/helpshift/migrator/MigrationFailureLogProvider;)Lcom/helpshift/network/HTTPTransport;
|
|
.locals 0
|
|
|
|
.line 45
|
|
iget-object p0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->httpTransport:Lcom/helpshift/network/HTTPTransport;
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
.method public static synthetic access$600(Lcom/helpshift/migrator/MigrationFailureLogProvider;)Ljava/lang/String;
|
|
.locals 0
|
|
|
|
.line 45
|
|
invoke-virtual {p0}, Lcom/helpshift/migrator/MigrationFailureLogProvider;->buildLogsRoute()Ljava/lang/String;
|
|
|
|
move-result-object p0
|
|
|
|
return-object p0
|
|
.end method
|
|
|
|
|
|
# virtual methods
|
|
.method public final buildLogsRoute()Ljava/lang/String;
|
|
.locals 2
|
|
|
|
.line 162
|
|
new-instance v0, Ljava/lang/StringBuilder;
|
|
|
|
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
const-string v1, "https://api."
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
iget-object v1, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->persistentStorage:Lcom/helpshift/storage/HSPersistentStorage;
|
|
|
|
invoke-virtual {v1}, Lcom/helpshift/storage/HSPersistentStorage;->getHost()Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
const-string v1, "/events/v1/"
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
iget-object v1, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->persistentStorage:Lcom/helpshift/storage/HSPersistentStorage;
|
|
|
|
.line 163
|
|
invoke-virtual {v1}, Lcom/helpshift/storage/HSPersistentStorage;->getDomain()Ljava/lang/String;
|
|
|
|
move-result-object v1
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
const-string v1, "/sdkx/crash-log"
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
move-result-object v0
|
|
|
|
return-object v0
|
|
.end method
|
|
|
|
.method public final jsonify(Ljava/lang/String;Ljava/lang/String;)Lorg/json/JSONObject;
|
|
.locals 1
|
|
|
|
.line 167
|
|
new-instance v0, Lorg/json/JSONObject;
|
|
|
|
invoke-direct {v0}, Lorg/json/JSONObject;-><init>()V
|
|
|
|
invoke-virtual {v0, p1, p2}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
|
|
|
|
move-result-object p1
|
|
|
|
return-object p1
|
|
.end method
|
|
|
|
.method public sendMigrationFailureLogs()V
|
|
.locals 3
|
|
|
|
iget-object v0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->preferences:Landroid/content/SharedPreferences;
|
|
|
|
const-string v1, "migration_state"
|
|
|
|
const/4 v2, 0x0
|
|
|
|
.line 71
|
|
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getInt(Ljava/lang/String;I)I
|
|
|
|
move-result v0
|
|
|
|
const/4 v1, 0x1
|
|
|
|
if-eq v0, v1, :cond_2
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
goto :goto_0
|
|
|
|
:cond_0
|
|
iget-object v0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->preferences:Landroid/content/SharedPreferences;
|
|
|
|
const-string v1, "failure_logs_synced"
|
|
|
|
.line 76
|
|
invoke-interface {v0, v1, v2}, Landroid/content/SharedPreferences;->getBoolean(Ljava/lang/String;Z)Z
|
|
|
|
move-result v0
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
return-void
|
|
|
|
:cond_1
|
|
iget-object v0, p0, Lcom/helpshift/migrator/MigrationFailureLogProvider;->hsThreadingService:Lcom/helpshift/concurrency/HSThreadingService;
|
|
|
|
.line 81
|
|
invoke-virtual {v0}, Lcom/helpshift/concurrency/HSThreadingService;->getNetworkService()Lcom/helpshift/concurrency/HSThreader;
|
|
|
|
move-result-object v0
|
|
|
|
new-instance v1, Lcom/helpshift/migrator/MigrationFailureLogProvider$1;
|
|
|
|
invoke-direct {v1, p0}, Lcom/helpshift/migrator/MigrationFailureLogProvider$1;-><init>(Lcom/helpshift/migrator/MigrationFailureLogProvider;)V
|
|
|
|
invoke-interface {v0, v1}, Lcom/helpshift/concurrency/HSThreader;->submit(Ljava/lang/Runnable;)V
|
|
|
|
:cond_2
|
|
:goto_0
|
|
return-void
|
|
.end method
|