StatementExecutor.smali
.class public Lcom/j256/ormlite/stmt/StatementExecutor;
.super Ljava/lang/Object;
.source "SourceFile"
# interfaces
.implements Lcom/j256/ormlite/stmt/GenericRowMapper;
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lcom/j256/ormlite/stmt/StatementExecutor$UserDatabaseResultsMapper;,
Lcom/j256/ormlite/stmt/StatementExecutor$ObjectArrayRowMapper;,
Lcom/j256/ormlite/stmt/StatementExecutor$UserRawRowObjectMapper;,
Lcom/j256/ormlite/stmt/StatementExecutor$UserRawRowMapper;
}
.end annotation
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
"ID:",
"Ljava/lang/Object;",
">",
"Ljava/lang/Object;",
"Lcom/j256/ormlite/stmt/GenericRowMapper<",
"[",
"Ljava/lang/String;",
">;"
}
.end annotation
# static fields
.field private static logger:Lcom/j256/ormlite/logger/Logger;
.field private static final noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
# instance fields
.field private countStarQuery:Ljava/lang/String;
.field private final dao:Lcom/j256/ormlite/dao/Dao;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/dao/Dao<",
"TT;TID;>;"
}
.end annotation
.end field
.field private final databaseType:Lcom/j256/ormlite/db/DatabaseType;
.field private ifExistsFieldTypes:[Lcom/j256/ormlite/field/FieldType;
.field private ifExistsQuery:Ljava/lang/String;
.field private final localIsInBatchMode:Ljava/lang/ThreadLocal;
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/ThreadLocal<",
"Ljava/lang/Boolean;",
">;"
}
.end annotation
.end field
.field private mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/mapped/MappedDelete<",
"TT;TID;>;"
}
.end annotation
.end field
.field private mappedInsert:Lcom/j256/ormlite/stmt/mapped/MappedCreate;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/mapped/MappedCreate<",
"TT;TID;>;"
}
.end annotation
.end field
.field private mappedQueryForId:Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq<",
"TT;TID;>;"
}
.end annotation
.end field
.field private mappedRefresh:Lcom/j256/ormlite/stmt/mapped/MappedRefresh;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/mapped/MappedRefresh<",
"TT;TID;>;"
}
.end annotation
.end field
.field private mappedUpdate:Lcom/j256/ormlite/stmt/mapped/MappedUpdate;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/mapped/MappedUpdate<",
"TT;TID;>;"
}
.end annotation
.end field
.field private mappedUpdateId:Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/mapped/MappedUpdateId<",
"TT;TID;>;"
}
.end annotation
.end field
.field private preparedQueryForAll:Lcom/j256/ormlite/stmt/PreparedQuery;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/stmt/PreparedQuery<",
"TT;>;"
}
.end annotation
.end field
.field private rawRowMapper:Lcom/j256/ormlite/dao/RawRowMapper;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/dao/RawRowMapper<",
"TT;>;"
}
.end annotation
.end field
.field private final tableInfo:Lcom/j256/ormlite/table/TableInfo;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lcom/j256/ormlite/table/TableInfo<",
"TT;TID;>;"
}
.end annotation
.end field
# direct methods
.method public static constructor <clinit>()V
.registers 1
.line 1
const-class v0, Lcom/j256/ormlite/stmt/StatementExecutor;
invoke-static {v0}, Lcom/j256/ormlite/logger/LoggerFactory;->getLogger(Ljava/lang/Class;)Lcom/j256/ormlite/logger/Logger;
move-result-object v0
sput-object v0, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const/4 v0, 0x0
new-array v0, v0, [Lcom/j256/ormlite/field/FieldType;
.line 2
sput-object v0, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
return-void
.end method
.method public constructor <init>(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;Lcom/j256/ormlite/dao/Dao;)V
.registers 5
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/db/DatabaseType;",
"Lcom/j256/ormlite/table/TableInfo<",
"TT;TID;>;",
"Lcom/j256/ormlite/dao/Dao<",
"TT;TID;>;)V"
}
.end annotation
.line 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 2
new-instance v0, Lcom/j256/ormlite/stmt/StatementExecutor$1;
invoke-direct {v0, p0}, Lcom/j256/ormlite/stmt/StatementExecutor$1;-><init>(Lcom/j256/ormlite/stmt/StatementExecutor;)V
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
.line 3
iput-object p1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
.line 4
iput-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
.line 5
iput-object p3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
return-void
.end method
.method private assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.registers 6
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const/4 v0, 0x0
.line 1
:goto_1
array-length v1, p2
if-ge v0, v1, :cond_e
.line 2
aget-object v1, p2, v0
sget-object v2, Lcom/j256/ormlite/field/SqlType;->STRING:Lcom/j256/ormlite/field/SqlType;
invoke-interface {p1, v0, v1, v2}, Lcom/j256/ormlite/support/CompiledStatement;->setObject(ILjava/lang/Object;Lcom/j256/ormlite/field/SqlType;)V
add-int/lit8 v0, v0, 0x1
goto :goto_1
:cond_e
return-void
.end method
.method private doCallBatchTasks(Lcom/j256/ormlite/support/ConnectionSource;Ljava/util/concurrent/Callable;)Ljava/lang/Object;
.registers 7
.annotation system Ldalvik/annotation/Signature;
value = {
"<CT:",
"Ljava/lang/Object;",
">(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/util/concurrent/Callable<",
"TCT;>;)TCT;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v0}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v0
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->getReadWriteConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v0
const/4 v1, 0x0
.line 2
:try_start_b
iget-object v2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
sget-object v3, Ljava/lang/Boolean;->TRUE:Ljava/lang/Boolean;
invoke-virtual {v2, v3}, Ljava/lang/ThreadLocal;->set(Ljava/lang/Object;)V
.line 3
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->saveSpecialConnection(Lcom/j256/ormlite/support/DatabaseConnection;)Z
move-result v1
.line 4
invoke-direct {p0, v0, v1, p2}, Lcom/j256/ormlite/stmt/StatementExecutor;->doCallBatchTasks(Lcom/j256/ormlite/support/DatabaseConnection;ZLjava/util/concurrent/Callable;)Ljava/lang/Object;
move-result-object p2
:try_end_1a
.catchall {:try_start_b .. :try_end_1a} :catchall_31
if-eqz v1, :cond_1f
.line 5
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->clearSpecialConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
.line 6
:cond_1f
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
.line 7
iget-object p1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
sget-object v0, Ljava/lang/Boolean;->FALSE:Ljava/lang/Boolean;
invoke-virtual {p1, v0}, Ljava/lang/ThreadLocal;->set(Ljava/lang/Object;)V
.line 8
iget-object p1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p1, :cond_30
.line 9
invoke-interface {p1}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_30
return-object p2
:catchall_31
move-exception p2
if-eqz v1, :cond_37
.line 10
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->clearSpecialConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
.line 11
:cond_37
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
.line 12
iget-object p1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
sget-object v0, Ljava/lang/Boolean;->FALSE:Ljava/lang/Boolean;
invoke-virtual {p1, v0}, Ljava/lang/ThreadLocal;->set(Ljava/lang/Object;)V
.line 13
iget-object p1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p1, :cond_48
.line 14
invoke-interface {p1}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_48
throw p2
.end method
.method private doCallBatchTasks(Lcom/j256/ormlite/support/DatabaseConnection;ZLjava/util/concurrent/Callable;)Ljava/lang/Object;
.registers 9
.annotation system Ldalvik/annotation/Signature;
value = {
"<CT:",
"Ljava/lang/Object;",
">(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Z",
"Ljava/util/concurrent/Callable<",
"TCT;>;)TCT;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "re-enabled auto-commit on table {} after batch tasks"
.line 15
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
invoke-interface {v1}, Lcom/j256/ormlite/db/DatabaseType;->isBatchUseTransaction()Z
move-result v1
if-eqz v1, :cond_11
.line 16
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
invoke-static {p1, p2, v0, p3}, Lcom/j256/ormlite/misc/TransactionManager;->callInTransaction(Lcom/j256/ormlite/support/DatabaseConnection;ZLcom/j256/ormlite/db/DatabaseType;Ljava/util/concurrent/Callable;)Ljava/lang/Object;
move-result-object p1
return-object p1
:cond_11
const/4 p2, 0x0
const/4 v1, 0x1
.line 17
:try_start_13
invoke-interface {p1}, Lcom/j256/ormlite/support/DatabaseConnection;->isAutoCommitSupported()Z
move-result v2
if-eqz v2, :cond_34
.line 18
invoke-interface {p1}, Lcom/j256/ormlite/support/DatabaseConnection;->isAutoCommit()Z
move-result v2
if-eqz v2, :cond_34
.line 19
invoke-interface {p1, p2}, Lcom/j256/ormlite/support/DatabaseConnection;->setAutoCommit(Z)V
:try_end_22
.catchall {:try_start_13 .. :try_end_22} :catchall_58
.line 20
:try_start_22
sget-object p2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "disabled auto-commit on table {} before batch tasks"
iget-object v3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v3}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v3
invoke-virtual {p2, v2, v3}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
:try_end_2f
.catchall {:try_start_22 .. :try_end_2f} :catchall_31
const/4 p2, 0x1
goto :goto_34
:catchall_31
move-exception p2
const/4 p3, 0x1
goto :goto_5b
.line 21
:cond_34
:goto_34
:try_start_34
invoke-interface {p3}, Ljava/util/concurrent/Callable;->call()Ljava/lang/Object;
move-result-object p3
:try_end_38
.catch Ljava/sql/SQLException; {:try_start_34 .. :try_end_38} :catch_56
.catch Ljava/lang/Exception; {:try_start_34 .. :try_end_38} :catch_4e
.catchall {:try_start_34 .. :try_end_38} :catchall_49
if-eqz p2, :cond_48
.line 22
invoke-interface {p1, v1}, Lcom/j256/ormlite/support/DatabaseConnection;->setAutoCommit(Z)V
.line 23
sget-object p1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {p2}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object p2
invoke-virtual {p1, v0, p2}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
:cond_48
return-object p3
:catchall_49
move-exception p3
move-object v4, p3
move p3, p2
move-object p2, v4
goto :goto_5b
:catch_4e
move-exception p3
:try_start_4f
const-string v2, "Batch tasks callable threw non-SQL exception"
.line 24
invoke-static {v2, p3}, Lcom/j256/ormlite/misc/SqlExceptionUtil;->create(Ljava/lang/String;Ljava/lang/Throwable;)Ljava/sql/SQLException;
move-result-object p3
throw p3
:catch_56
move-exception p3
.line 25
throw p3
:try_end_58
.catchall {:try_start_4f .. :try_end_58} :catchall_49
:catchall_58
move-exception p3
move-object p2, p3
const/4 p3, 0x0
:goto_5b
if-eqz p3, :cond_6b
.line 26
invoke-interface {p1, v1}, Lcom/j256/ormlite/support/DatabaseConnection;->setAutoCommit(Z)V
.line 27
sget-object p1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
iget-object p3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {p3}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object p3
invoke-virtual {p1, v0, p3}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
:cond_6b
throw p2
.end method
.method private prepareQueryForAll()V
.registers 5
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->preparedQueryForAll:Lcom/j256/ormlite/stmt/PreparedQuery;
if-nez v0, :cond_15
.line 2
new-instance v0, Lcom/j256/ormlite/stmt/QueryBuilder;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
iget-object v3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-direct {v0, v1, v2, v3}, Lcom/j256/ormlite/stmt/QueryBuilder;-><init>(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;Lcom/j256/ormlite/dao/Dao;)V
invoke-virtual {v0}, Lcom/j256/ormlite/stmt/QueryBuilder;->prepare()Lcom/j256/ormlite/stmt/PreparedQuery;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->preparedQueryForAll:Lcom/j256/ormlite/stmt/PreparedQuery;
:cond_15
return-void
.end method
# virtual methods
.method public buildIterator(Lcom/j256/ormlite/dao/BaseDaoImpl;Lcom/j256/ormlite/support/ConnectionSource;ILcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/stmt/SelectIterator;
.registers 11
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/dao/BaseDaoImpl<",
"TT;TID;>;",
"Lcom/j256/ormlite/support/ConnectionSource;",
"I",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Lcom/j256/ormlite/stmt/SelectIterator<",
"TT;TID;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
invoke-direct {p0}, Lcom/j256/ormlite/stmt/StatementExecutor;->prepareQueryForAll()V
.line 2
iget-object v3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->preparedQueryForAll:Lcom/j256/ormlite/stmt/PreparedQuery;
move-object v0, p0
move-object v1, p1
move-object v2, p2
move-object v4, p4
move v5, p3
invoke-virtual/range {v0 .. v5}, Lcom/j256/ormlite/stmt/StatementExecutor;->buildIterator(Lcom/j256/ormlite/dao/BaseDaoImpl;Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/stmt/PreparedStmt;Lcom/j256/ormlite/dao/ObjectCache;I)Lcom/j256/ormlite/stmt/SelectIterator;
move-result-object p1
return-object p1
.end method
.method public buildIterator(Lcom/j256/ormlite/dao/BaseDaoImpl;Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/stmt/PreparedStmt;Lcom/j256/ormlite/dao/ObjectCache;I)Lcom/j256/ormlite/stmt/SelectIterator;
.registers 22
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/dao/BaseDaoImpl<",
"TT;TID;>;",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Lcom/j256/ormlite/stmt/PreparedStmt<",
"TT;>;",
"Lcom/j256/ormlite/dao/ObjectCache;",
"I)",
"Lcom/j256/ormlite/stmt/SelectIterator<",
"TT;TID;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
move-object/from16 v1, p0
move-object/from16 v11, p2
const-string v12, "compiled statement"
.line 3
iget-object v0, v1, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v0}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v0
invoke-interface {v11, v0}, Lcom/j256/ormlite/support/ConnectionSource;->getReadOnlyConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v13
const/4 v14, 0x0
.line 4
:try_start_11
sget-object v0, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
move-object/from16 v5, p3
move/from16 v2, p5
invoke-interface {v5, v13, v0, v2}, Lcom/j256/ormlite/stmt/PreparedStmt;->compile(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;I)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object v15
:try_end_1b
.catchall {:try_start_11 .. :try_end_1b} :catchall_3c
.line 5
:try_start_1b
new-instance v0, Lcom/j256/ormlite/stmt/SelectIterator;
iget-object v2, v1, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v2}, Lcom/j256/ormlite/table/TableInfo;->getDataClass()Ljava/lang/Class;
move-result-object v3
invoke-interface/range {p3 .. p3}, Lcom/j256/ormlite/stmt/PreparedStmt;->getStatement()Ljava/lang/String;
move-result-object v9
move-object v2, v0
move-object/from16 v4, p1
move-object/from16 v5, p3
move-object/from16 v6, p2
move-object v7, v13
move-object v8, v15
move-object/from16 v10, p4
invoke-direct/range {v2 .. v10}, Lcom/j256/ormlite/stmt/SelectIterator;-><init>(Ljava/lang/Class;Lcom/j256/ormlite/dao/Dao;Lcom/j256/ormlite/stmt/GenericRowMapper;Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/support/CompiledStatement;Ljava/lang/String;Lcom/j256/ormlite/dao/ObjectCache;)V
:try_end_35
.catchall {:try_start_1b .. :try_end_35} :catchall_39
.line 6
invoke-static {v14, v12}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v0
:catchall_39
move-exception v0
move-object v14, v15
goto :goto_3d
:catchall_3c
move-exception v0
:goto_3d
invoke-static {v14, v12}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
if-eqz v13, :cond_45
.line 7
invoke-interface {v11, v13}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
:cond_45
throw v0
.end method
.method public callBatchTasks(Lcom/j256/ormlite/support/ConnectionSource;Ljava/util/concurrent/Callable;)Ljava/lang/Object;
.registers 4
.annotation system Ldalvik/annotation/Signature;
value = {
"<CT:",
"Ljava/lang/Object;",
">(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/util/concurrent/Callable<",
"TCT;>;)TCT;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v0}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v0
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/ConnectionSource;->isSingleConnection(Ljava/lang/String;)Z
move-result v0
if-eqz v0, :cond_16
.line 2
monitor-enter p0
.line 3
:try_start_d
invoke-direct {p0, p1, p2}, Lcom/j256/ormlite/stmt/StatementExecutor;->doCallBatchTasks(Lcom/j256/ormlite/support/ConnectionSource;Ljava/util/concurrent/Callable;)Ljava/lang/Object;
move-result-object p1
monitor-exit p0
return-object p1
:catchall_13
move-exception p1
.line 4
monitor-exit p0
:try_end_15
.catchall {:try_start_d .. :try_end_15} :catchall_13
throw p1
.line 5
:cond_16
invoke-direct {p0, p1, p2}, Lcom/j256/ormlite/stmt/StatementExecutor;->doCallBatchTasks(Lcom/j256/ormlite/support/ConnectionSource;Ljava/util/concurrent/Callable;)Ljava/lang/Object;
move-result-object p1
return-object p1
.end method
.method public create(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TT;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedInsert:Lcom/j256/ormlite/stmt/mapped/MappedCreate;
if-nez v0, :cond_e
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1}, Lcom/j256/ormlite/stmt/mapped/MappedCreate;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;)Lcom/j256/ormlite/stmt/mapped/MappedCreate;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedInsert:Lcom/j256/ormlite/stmt/mapped/MappedCreate;
.line 3
:cond_e
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedInsert:Lcom/j256/ormlite/stmt/mapped/MappedCreate;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
invoke-virtual {v0, v1, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedCreate;->insert(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 4
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_2d
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_2d
.line 5
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_2d
return p1
.end method
.method public delete(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/PreparedDelete;)I
.registers 5
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Lcom/j256/ormlite/stmt/PreparedDelete<",
"TT;>;)I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
.line 6
sget-object v1, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->DELETE:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
invoke-interface {p2, p1, v1}, Lcom/j256/ormlite/stmt/PreparedDelete;->compile(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
.line 7
:try_start_8
invoke-interface {p1}, Lcom/j256/ormlite/support/CompiledStatement;->runUpdate()I
move-result p2
.line 8
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz v1, :cond_23
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {v1}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object v1
check-cast v1, Ljava/lang/Boolean;
invoke-virtual {v1}, Ljava/lang/Boolean;->booleanValue()Z
move-result v1
if-nez v1, :cond_23
.line 9
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {v1}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:try_end_23
.catchall {:try_start_8 .. :try_end_23} :catchall_27
.line 10
:cond_23
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return p2
:catchall_27
move-exception p2
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public delete(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TT;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
if-nez v0, :cond_e
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1}, Lcom/j256/ormlite/stmt/mapped/MappedDelete;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;)Lcom/j256/ormlite/stmt/mapped/MappedDelete;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
.line 3
:cond_e
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
invoke-virtual {v0, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedDelete;->delete(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 4
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_2b
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_2b
.line 5
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_2b
return p1
.end method
.method public deleteById(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TID;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
if-nez v0, :cond_e
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1}, Lcom/j256/ormlite/stmt/mapped/MappedDelete;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;)Lcom/j256/ormlite/stmt/mapped/MappedDelete;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
.line 3
:cond_e
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedDelete:Lcom/j256/ormlite/stmt/mapped/MappedDelete;
invoke-virtual {v0, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedDelete;->deleteById(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 4
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_2b
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_2b
.line 5
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_2b
return p1
.end method
.method public deleteIds(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/util/Collection;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Ljava/util/Collection<",
"TID;>;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedDeleteCollection;->deleteIds(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/util/Collection;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 2
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_1f
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_1f
.line 3
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_1f
return p1
.end method
.method public deleteObjects(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/util/Collection;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Ljava/util/Collection<",
"TT;>;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedDeleteCollection;->deleteObjects(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/util/Collection;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 2
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_1f
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_1f
.line 3
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_1f
return p1
.end method
.method public executeRaw(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;[Ljava/lang/String;)I
.registers 13
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
.line 1
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "running raw execute statement: {}"
invoke-virtual {v1, v2, p2}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 2
array-length v1, p3
if-lez v1, :cond_13
.line 3
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "execute arguments: {}"
invoke-virtual {v1, v2, p3}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 4
:cond_13
sget-object v5, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->EXECUTE:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v6, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v7, -0x1
const/4 v8, 0x0
move-object v3, p1
move-object v4, p2
invoke-interface/range {v3 .. v8}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
.line 5
:try_start_1f
invoke-direct {p0, p1, p3}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 6
invoke-interface {p1}, Lcom/j256/ormlite/support/CompiledStatement;->runExecute()I
move-result p2
:try_end_26
.catchall {:try_start_1f .. :try_end_26} :catchall_2a
.line 7
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return p2
:catchall_2a
move-exception p2
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public executeRawNoArgs(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;)I
.registers 5
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
sget-object v0, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v1, "running raw execute statement: {}"
invoke-virtual {v0, v1, p2}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
const/4 v0, -0x1
.line 2
invoke-interface {p1, p2, v0}, Lcom/j256/ormlite/support/DatabaseConnection;->executeStatement(Ljava/lang/String;I)I
move-result p1
return p1
.end method
.method public getRawRowMapper()Lcom/j256/ormlite/dao/RawRowMapper;
.registers 3
.annotation system Ldalvik/annotation/Signature;
value = {
"()",
"Lcom/j256/ormlite/dao/RawRowMapper<",
"TT;>;"
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->rawRowMapper:Lcom/j256/ormlite/dao/RawRowMapper;
if-nez v0, :cond_d
.line 2
new-instance v0, Lcom/j256/ormlite/stmt/RawRowMapperImpl;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-direct {v0, v1}, Lcom/j256/ormlite/stmt/RawRowMapperImpl;-><init>(Lcom/j256/ormlite/table/TableInfo;)V
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->rawRowMapper:Lcom/j256/ormlite/dao/RawRowMapper;
.line 3
:cond_d
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->rawRowMapper:Lcom/j256/ormlite/dao/RawRowMapper;
return-object v0
.end method
.method public getSelectStarRowMapper()Lcom/j256/ormlite/stmt/GenericRowMapper;
.registers 2
.annotation system Ldalvik/annotation/Signature;
value = {
"()",
"Lcom/j256/ormlite/stmt/GenericRowMapper<",
"TT;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
invoke-direct {p0}, Lcom/j256/ormlite/stmt/StatementExecutor;->prepareQueryForAll()V
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->preparedQueryForAll:Lcom/j256/ormlite/stmt/PreparedQuery;
return-object v0
.end method
.method public ifExists(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;)Z
.registers 9
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TID;)Z"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->ifExistsQuery:Ljava/lang/String;
const/4 v1, 0x0
const/4 v2, 0x1
if-nez v0, :cond_42
.line 2
new-instance v0, Lcom/j256/ormlite/stmt/QueryBuilder;
iget-object v3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v4, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
iget-object v5, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-direct {v0, v3, v4, v5}, Lcom/j256/ormlite/stmt/QueryBuilder;-><init>(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;Lcom/j256/ormlite/dao/Dao;)V
const-string v3, "COUNT(*)"
.line 3
filled-new-array {v3}, [Ljava/lang/String;
move-result-object v3
invoke-virtual {v0, v3}, Lcom/j256/ormlite/stmt/QueryBuilder;->selectRaw([Ljava/lang/String;)Lcom/j256/ormlite/stmt/QueryBuilder;
.line 4
invoke-virtual {v0}, Lcom/j256/ormlite/stmt/StatementBuilder;->where()Lcom/j256/ormlite/stmt/Where;
move-result-object v3
iget-object v4, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v4}, Lcom/j256/ormlite/table/TableInfo;->getIdField()Lcom/j256/ormlite/field/FieldType;
move-result-object v4
invoke-virtual {v4}, Lcom/j256/ormlite/field/FieldType;->getColumnName()Ljava/lang/String;
move-result-object v4
new-instance v5, Lcom/j256/ormlite/stmt/SelectArg;
invoke-direct {v5}, Lcom/j256/ormlite/stmt/SelectArg;-><init>()V
invoke-virtual {v3, v4, v5}, Lcom/j256/ormlite/stmt/Where;->eq(Ljava/lang/String;Ljava/lang/Object;)Lcom/j256/ormlite/stmt/Where;
.line 5
invoke-virtual {v0}, Lcom/j256/ormlite/stmt/StatementBuilder;->prepareStatementString()Ljava/lang/String;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->ifExistsQuery:Ljava/lang/String;
new-array v0, v2, [Lcom/j256/ormlite/field/FieldType;
.line 6
iget-object v3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v3}, Lcom/j256/ormlite/table/TableInfo;->getIdField()Lcom/j256/ormlite/field/FieldType;
move-result-object v3
aput-object v3, v0, v1
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->ifExistsFieldTypes:[Lcom/j256/ormlite/field/FieldType;
.line 7
:cond_42
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v0}, Lcom/j256/ormlite/table/TableInfo;->getIdField()Lcom/j256/ormlite/field/FieldType;
move-result-object v0
invoke-virtual {v0, p2}, Lcom/j256/ormlite/field/FieldType;->convertJavaFieldToSqlArgValue(Ljava/lang/Object;)Ljava/lang/Object;
move-result-object p2
.line 8
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->ifExistsQuery:Ljava/lang/String;
new-array v3, v2, [Ljava/lang/Object;
aput-object p2, v3, v1
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->ifExistsFieldTypes:[Lcom/j256/ormlite/field/FieldType;
invoke-interface {p1, v0, v3, p2}, Lcom/j256/ormlite/support/DatabaseConnection;->queryForLong(Ljava/lang/String;[Ljava/lang/Object;[Lcom/j256/ormlite/field/FieldType;)J
move-result-wide p1
.line 9
sget-object v0, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
iget-object v3, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->ifExistsQuery:Ljava/lang/String;
invoke-static {p1, p2}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
move-result-object v4
const-string v5, "query of \'{}\' returned {}"
invoke-virtual {v0, v5, v3, v4}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)V
const-wide/16 v3, 0x0
cmp-long v0, p1, v3
if-eqz v0, :cond_6c
const/4 v1, 0x1
:cond_6c
return v1
.end method
.method public bridge synthetic mapRow(Lcom/j256/ormlite/support/DatabaseResults;)Ljava/lang/Object;
.registers 2
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
invoke-virtual {p0, p1}, Lcom/j256/ormlite/stmt/StatementExecutor;->mapRow(Lcom/j256/ormlite/support/DatabaseResults;)[Ljava/lang/String;
move-result-object p1
return-object p1
.end method
.method public mapRow(Lcom/j256/ormlite/support/DatabaseResults;)[Ljava/lang/String;
.registers 6
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 2
invoke-interface {p1}, Lcom/j256/ormlite/support/DatabaseResults;->getColumnCount()I
move-result v0
.line 3
new-array v1, v0, [Ljava/lang/String;
const/4 v2, 0x0
:goto_7
if-ge v2, v0, :cond_12
.line 4
invoke-interface {p1, v2}, Lcom/j256/ormlite/support/DatabaseResults;->getString(I)Ljava/lang/String;
move-result-object v3
aput-object v3, v1, v2
add-int/lit8 v2, v2, 0x1
goto :goto_7
:cond_12
return-object v1
.end method
.method public query(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/stmt/PreparedStmt;Lcom/j256/ormlite/dao/ObjectCache;)Ljava/util/List;
.registers 11
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Lcom/j256/ormlite/stmt/PreparedStmt<",
"TT;>;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Ljava/util/List<",
"TT;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "iterator"
const/4 v2, 0x0
const/4 v6, -0x1
move-object v1, p0
move-object v3, p1
move-object v4, p2
move-object v5, p3
.line 1
invoke-virtual/range {v1 .. v6}, Lcom/j256/ormlite/stmt/StatementExecutor;->buildIterator(Lcom/j256/ormlite/dao/BaseDaoImpl;Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/stmt/PreparedStmt;Lcom/j256/ormlite/dao/ObjectCache;I)Lcom/j256/ormlite/stmt/SelectIterator;
move-result-object p1
.line 2
:try_start_c
new-instance p3, Ljava/util/ArrayList;
invoke-direct {p3}, Ljava/util/ArrayList;-><init>()V
.line 3
:goto_11
invoke-virtual {p1}, Lcom/j256/ormlite/stmt/SelectIterator;->hasNextThrow()Z
move-result v1
if-eqz v1, :cond_1f
.line 4
invoke-virtual {p1}, Lcom/j256/ormlite/stmt/SelectIterator;->nextThrow()Ljava/lang/Object;
move-result-object v1
invoke-virtual {p3, v1}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z
goto :goto_11
.line 5
:cond_1f
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "query of \'{}\' returned {} results"
invoke-interface {p2}, Lcom/j256/ormlite/stmt/PreparedStmt;->getStatement()Ljava/lang/String;
move-result-object p2
invoke-virtual {p3}, Ljava/util/ArrayList;->size()I
move-result v3
invoke-static {v3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object v3
invoke-virtual {v1, v2, p2, v3}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)V
:try_end_32
.catchall {:try_start_c .. :try_end_32} :catchall_36
.line 6
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object p3
:catchall_36
move-exception p2
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public queryForAll(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/dao/ObjectCache;)Ljava/util/List;
.registers 4
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Ljava/util/List<",
"TT;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
invoke-direct {p0}, Lcom/j256/ormlite/stmt/StatementExecutor;->prepareQueryForAll()V
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->preparedQueryForAll:Lcom/j256/ormlite/stmt/PreparedQuery;
invoke-virtual {p0, p1, v0, p2}, Lcom/j256/ormlite/stmt/StatementExecutor;->query(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/stmt/PreparedStmt;Lcom/j256/ormlite/dao/ObjectCache;)Ljava/util/List;
move-result-object p1
return-object p1
.end method
.method public queryForCountStar(Lcom/j256/ormlite/support/DatabaseConnection;)J
.registers 7
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->countStarQuery:Ljava/lang/String;
if-nez v0, :cond_21
.line 2
new-instance v0, Ljava/lang/StringBuilder;
const/16 v1, 0x40
invoke-direct {v0, v1}, Ljava/lang/StringBuilder;-><init>(I)V
const-string v1, "SELECT COUNT(*) FROM "
.line 3
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
.line 4
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v2}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v2
invoke-interface {v1, v0, v2}, Lcom/j256/ormlite/db/DatabaseType;->appendEscapedEntityName(Ljava/lang/StringBuilder;Ljava/lang/String;)V
.line 5
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->countStarQuery:Ljava/lang/String;
.line 6
:cond_21
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->countStarQuery:Ljava/lang/String;
invoke-interface {p1, v0}, Lcom/j256/ormlite/support/DatabaseConnection;->queryForLong(Ljava/lang/String;)J
move-result-wide v0
.line 7
sget-object p1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
iget-object v2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->countStarQuery:Ljava/lang/String;
invoke-static {v0, v1}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
move-result-object v3
const-string v4, "query of \'{}\' returned {}"
invoke-virtual {p1, v4, v2, v3}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)V
return-wide v0
.end method
.method public queryForFirst(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/PreparedStmt;Lcom/j256/ormlite/dao/ObjectCache;)Ljava/lang/Object;
.registers 9
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Lcom/j256/ormlite/stmt/PreparedStmt<",
"TT;>;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")TT;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
const-string v1, "results"
.line 1
sget-object v2, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
invoke-interface {p2, p1, v2}, Lcom/j256/ormlite/stmt/PreparedStmt;->compile(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
const/4 v2, 0x1
const/4 v3, 0x0
.line 2
:try_start_c
invoke-interface {p1, v2}, Lcom/j256/ormlite/support/CompiledStatement;->setMaxRows(I)V
.line 3
invoke-interface {p1, p3}, Lcom/j256/ormlite/support/CompiledStatement;->runQuery(Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/support/DatabaseResults;
move-result-object p3
:try_end_13
.catchall {:try_start_c .. :try_end_13} :catchall_44
.line 4
:try_start_13
invoke-interface {p3}, Lcom/j256/ormlite/support/DatabaseResults;->first()Z
move-result v2
if-eqz v2, :cond_2f
.line 5
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "query-for-first of \'{}\' returned at least 1 result"
invoke-interface {p2}, Lcom/j256/ormlite/stmt/PreparedStmt;->getStatement()Ljava/lang/String;
move-result-object v4
invoke-virtual {v2, v3, v4}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 6
invoke-interface {p2, p3}, Lcom/j256/ormlite/stmt/PreparedStmt;->mapRow(Lcom/j256/ormlite/support/DatabaseResults;)Ljava/lang/Object;
move-result-object p2
:try_end_28
.catchall {:try_start_13 .. :try_end_28} :catchall_41
.line 7
invoke-static {p3, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 8
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object p2
.line 9
:cond_2f
:try_start_2f
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v4, "query-for-first of \'{}\' returned at 0 results"
invoke-interface {p2}, Lcom/j256/ormlite/stmt/PreparedStmt;->getStatement()Ljava/lang/String;
move-result-object p2
invoke-virtual {v2, v4, p2}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
:try_end_3a
.catchall {:try_start_2f .. :try_end_3a} :catchall_41
.line 10
invoke-static {p3, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 11
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v3
:catchall_41
move-exception p2
move-object v3, p3
goto :goto_45
:catchall_44
move-exception p2
.line 12
:goto_45
invoke-static {v3, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 13
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public queryForId(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)Ljava/lang/Object;
.registers 7
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TID;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")TT;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedQueryForId:Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;
if-nez v0, :cond_f
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
const/4 v2, 0x0
invoke-static {v0, v1, v2}, Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;Lcom/j256/ormlite/field/FieldType;)Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedQueryForId:Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;
.line 3
:cond_f
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedQueryForId:Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;
invoke-virtual {v0, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedQueryForFieldEq;->execute(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)Ljava/lang/Object;
move-result-object p1
return-object p1
.end method
.method public queryForLong(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/PreparedStmt;)J
.registers 9
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Lcom/j256/ormlite/stmt/PreparedStmt<",
"TT;>;)J"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
const-string v1, "results"
.line 1
sget-object v2, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT_LONG:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
invoke-interface {p2, p1, v2}, Lcom/j256/ormlite/stmt/PreparedStmt;->compile(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
const/4 v2, 0x0
.line 2
:try_start_b
invoke-interface {p1, v2}, Lcom/j256/ormlite/support/CompiledStatement;->runQuery(Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/support/DatabaseResults;
move-result-object v2
.line 3
invoke-interface {v2}, Lcom/j256/ormlite/support/DatabaseResults;->first()Z
move-result v3
if-eqz v3, :cond_21
const/4 p2, 0x0
.line 4
invoke-interface {v2, p2}, Lcom/j256/ormlite/support/DatabaseResults;->getLong(I)J
move-result-wide v3
:try_end_1a
.catchall {:try_start_b .. :try_end_1a} :catchall_3c
.line 5
invoke-static {v2, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 6
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-wide v3
.line 7
:cond_21
:try_start_21
new-instance v3, Ljava/sql/SQLException;
new-instance v4, Ljava/lang/StringBuilder;
invoke-direct {v4}, Ljava/lang/StringBuilder;-><init>()V
const-string v5, "No result found in queryForLong: "
invoke-virtual {v4, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-interface {p2}, Lcom/j256/ormlite/stmt/PreparedStmt;->getStatement()Ljava/lang/String;
move-result-object p2
invoke-virtual {v4, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v4}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p2
invoke-direct {v3, p2}, Ljava/sql/SQLException;-><init>(Ljava/lang/String;)V
throw v3
:try_end_3c
.catchall {:try_start_21 .. :try_end_3c} :catchall_3c
:catchall_3c
move-exception p2
.line 8
invoke-static {v2, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 9
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public queryForLong(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;[Ljava/lang/String;)J
.registers 13
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
const-string v1, "results"
.line 10
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "executing raw query for long: {}"
invoke-virtual {v2, v3, p2}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 11
array-length v2, p3
if-lez v2, :cond_15
.line 12
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "query arguments: {}"
invoke-virtual {v2, v3, p3}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
:cond_15
const/4 v2, 0x0
.line 13
:try_start_16
sget-object v5, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v6, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v7, -0x1
const/4 v8, 0x0
move-object v3, p1
move-object v4, p2
invoke-interface/range {v3 .. v8}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
:try_end_22
.catchall {:try_start_16 .. :try_end_22} :catchall_54
.line 14
:try_start_22
invoke-direct {p0, p1, p3}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 15
invoke-interface {p1, v2}, Lcom/j256/ormlite/support/CompiledStatement;->runQuery(Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/support/DatabaseResults;
move-result-object v2
.line 16
invoke-interface {v2}, Lcom/j256/ormlite/support/DatabaseResults;->first()Z
move-result p3
if-eqz p3, :cond_3b
const/4 p2, 0x0
.line 17
invoke-interface {v2, p2}, Lcom/j256/ormlite/support/DatabaseResults;->getLong(I)J
move-result-wide p2
:try_end_34
.catchall {:try_start_22 .. :try_end_34} :catchall_52
.line 18
invoke-static {v2, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 19
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-wide p2
.line 20
:cond_3b
:try_start_3b
new-instance p3, Ljava/sql/SQLException;
new-instance v3, Ljava/lang/StringBuilder;
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
const-string v4, "No result found in queryForLong: "
invoke-virtual {v3, v4}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v3, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p2
invoke-direct {p3, p2}, Ljava/sql/SQLException;-><init>(Ljava/lang/String;)V
throw p3
:try_end_52
.catchall {:try_start_3b .. :try_end_52} :catchall_52
:catchall_52
move-exception p2
goto :goto_56
:catchall_54
move-exception p2
move-object p1, v2
.line 21
:goto_56
invoke-static {v2, v1}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
.line 22
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public queryRaw(Lcom/j256/ormlite/support/ConnectionSource;Ljava/lang/String;Lcom/j256/ormlite/dao/DatabaseResultsMapper;[Ljava/lang/String;Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/dao/GenericRawResults;
.registers 22
.annotation system Ldalvik/annotation/Signature;
value = {
"<UO:",
"Ljava/lang/Object;",
">(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/DatabaseResultsMapper<",
"TUO;>;[",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Lcom/j256/ormlite/dao/GenericRawResults<",
"TUO;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
move-object/from16 v1, p0
move-object/from16 v10, p1
move-object/from16 v0, p4
const-string v11, "compiled statement"
.line 37
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "executing raw query for: {}"
move-object/from16 v12, p2
invoke-virtual {v2, v3, v12}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 38
array-length v2, v0
if-lez v2, :cond_1b
.line 39
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "query arguments: {}"
invoke-virtual {v2, v3, v0}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 40
:cond_1b
iget-object v2, v1, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v2}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v2
invoke-interface {v10, v2}, Lcom/j256/ormlite/support/ConnectionSource;->getReadOnlyConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v13
const/4 v14, 0x0
.line 41
:try_start_26
sget-object v6, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v7, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v8, -0x1
const/4 v9, 0x0
move-object v4, v13
move-object/from16 v5, p2
invoke-interface/range {v4 .. v9}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object v15
:try_end_33
.catchall {:try_start_26 .. :try_end_33} :catchall_54
.line 42
:try_start_33
invoke-direct {v1, v15, v0}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 43
new-instance v0, Lcom/j256/ormlite/stmt/RawResultsImpl;
const-class v6, [Ljava/lang/Object;
new-instance v8, Lcom/j256/ormlite/stmt/StatementExecutor$UserDatabaseResultsMapper;
move-object/from16 v2, p3
invoke-direct {v8, v2, v14}, Lcom/j256/ormlite/stmt/StatementExecutor$UserDatabaseResultsMapper;-><init>(Lcom/j256/ormlite/dao/DatabaseResultsMapper;Lcom/j256/ormlite/stmt/StatementExecutor$1;)V
move-object v2, v0
move-object/from16 v3, p1
move-object v4, v13
move-object/from16 v5, p2
move-object v7, v15
move-object/from16 v9, p5
invoke-direct/range {v2 .. v9}, Lcom/j256/ormlite/stmt/RawResultsImpl;-><init>(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;Ljava/lang/Class;Lcom/j256/ormlite/support/CompiledStatement;Lcom/j256/ormlite/stmt/GenericRowMapper;Lcom/j256/ormlite/dao/ObjectCache;)V
:try_end_4d
.catchall {:try_start_33 .. :try_end_4d} :catchall_51
.line 44
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v0
:catchall_51
move-exception v0
move-object v14, v15
goto :goto_55
:catchall_54
move-exception v0
:goto_55
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
if-eqz v13, :cond_5d
.line 45
invoke-interface {v10, v13}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
:cond_5d
throw v0
.end method
.method public queryRaw(Lcom/j256/ormlite/support/ConnectionSource;Ljava/lang/String;Lcom/j256/ormlite/dao/RawRowMapper;[Ljava/lang/String;Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/dao/GenericRawResults;
.registers 22
.annotation system Ldalvik/annotation/Signature;
value = {
"<UO:",
"Ljava/lang/Object;",
">(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/RawRowMapper<",
"TUO;>;[",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Lcom/j256/ormlite/dao/GenericRawResults<",
"TUO;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
move-object/from16 v1, p0
move-object/from16 v10, p1
move-object/from16 v0, p4
const-string v11, "compiled statement"
.line 10
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "executing raw query for: {}"
move-object/from16 v12, p2
invoke-virtual {v2, v3, v12}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 11
array-length v2, v0
if-lez v2, :cond_1b
.line 12
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "query arguments: {}"
invoke-virtual {v2, v3, v0}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 13
:cond_1b
iget-object v2, v1, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v2}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v2
invoke-interface {v10, v2}, Lcom/j256/ormlite/support/ConnectionSource;->getReadOnlyConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v13
const/4 v14, 0x0
.line 14
:try_start_26
sget-object v6, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v7, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v8, -0x1
const/4 v9, 0x0
move-object v4, v13
move-object/from16 v5, p2
invoke-interface/range {v4 .. v9}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object v15
:try_end_33
.catchall {:try_start_26 .. :try_end_33} :catchall_54
.line 15
:try_start_33
invoke-direct {v1, v15, v0}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 16
new-instance v0, Lcom/j256/ormlite/stmt/RawResultsImpl;
const-class v6, [Ljava/lang/String;
new-instance v8, Lcom/j256/ormlite/stmt/StatementExecutor$UserRawRowMapper;
move-object/from16 v2, p3
invoke-direct {v8, v2, v1}, Lcom/j256/ormlite/stmt/StatementExecutor$UserRawRowMapper;-><init>(Lcom/j256/ormlite/dao/RawRowMapper;Lcom/j256/ormlite/stmt/GenericRowMapper;)V
move-object v2, v0
move-object/from16 v3, p1
move-object v4, v13
move-object/from16 v5, p2
move-object v7, v15
move-object/from16 v9, p5
invoke-direct/range {v2 .. v9}, Lcom/j256/ormlite/stmt/RawResultsImpl;-><init>(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;Ljava/lang/Class;Lcom/j256/ormlite/support/CompiledStatement;Lcom/j256/ormlite/stmt/GenericRowMapper;Lcom/j256/ormlite/dao/ObjectCache;)V
:try_end_4d
.catchall {:try_start_33 .. :try_end_4d} :catchall_51
.line 17
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v0
:catchall_51
move-exception v0
move-object v14, v15
goto :goto_55
:catchall_54
move-exception v0
:goto_55
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
if-eqz v13, :cond_5d
.line 18
invoke-interface {v10, v13}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
:cond_5d
throw v0
.end method
.method public queryRaw(Lcom/j256/ormlite/support/ConnectionSource;Ljava/lang/String;[Lcom/j256/ormlite/field/DataType;Lcom/j256/ormlite/dao/RawRowObjectMapper;[Ljava/lang/String;Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/dao/GenericRawResults;
.registers 23
.annotation system Ldalvik/annotation/Signature;
value = {
"<UO:",
"Ljava/lang/Object;",
">(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/lang/String;",
"[",
"Lcom/j256/ormlite/field/DataType;",
"Lcom/j256/ormlite/dao/RawRowObjectMapper<",
"TUO;>;[",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Lcom/j256/ormlite/dao/GenericRawResults<",
"TUO;>;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
move-object/from16 v1, p0
move-object/from16 v10, p1
move-object/from16 v0, p5
const-string v11, "compiled statement"
.line 19
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "executing raw query for: {}"
move-object/from16 v12, p2
invoke-virtual {v2, v3, v12}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 20
array-length v2, v0
if-lez v2, :cond_1b
.line 21
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "query arguments: {}"
invoke-virtual {v2, v3, v0}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 22
:cond_1b
iget-object v2, v1, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v2}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v2
invoke-interface {v10, v2}, Lcom/j256/ormlite/support/ConnectionSource;->getReadOnlyConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v13
const/4 v14, 0x0
.line 23
:try_start_26
sget-object v6, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v7, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v8, -0x1
const/4 v9, 0x0
move-object v4, v13
move-object/from16 v5, p2
invoke-interface/range {v4 .. v9}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object v15
:try_end_33
.catchall {:try_start_26 .. :try_end_33} :catchall_56
.line 24
:try_start_33
invoke-direct {v1, v15, v0}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 25
new-instance v0, Lcom/j256/ormlite/stmt/RawResultsImpl;
const-class v6, [Ljava/lang/String;
new-instance v8, Lcom/j256/ormlite/stmt/StatementExecutor$UserRawRowObjectMapper;
move-object/from16 v2, p3
move-object/from16 v3, p4
invoke-direct {v8, v3, v2}, Lcom/j256/ormlite/stmt/StatementExecutor$UserRawRowObjectMapper;-><init>(Lcom/j256/ormlite/dao/RawRowObjectMapper;[Lcom/j256/ormlite/field/DataType;)V
move-object v2, v0
move-object/from16 v3, p1
move-object v4, v13
move-object/from16 v5, p2
move-object v7, v15
move-object/from16 v9, p6
invoke-direct/range {v2 .. v9}, Lcom/j256/ormlite/stmt/RawResultsImpl;-><init>(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;Ljava/lang/Class;Lcom/j256/ormlite/support/CompiledStatement;Lcom/j256/ormlite/stmt/GenericRowMapper;Lcom/j256/ormlite/dao/ObjectCache;)V
:try_end_4f
.catchall {:try_start_33 .. :try_end_4f} :catchall_53
.line 26
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v0
:catchall_53
move-exception v0
move-object v14, v15
goto :goto_57
:catchall_56
move-exception v0
:goto_57
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
if-eqz v13, :cond_5f
.line 27
invoke-interface {v10, v13}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
:cond_5f
throw v0
.end method
.method public queryRaw(Lcom/j256/ormlite/support/ConnectionSource;Ljava/lang/String;[Lcom/j256/ormlite/field/DataType;[Ljava/lang/String;Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/dao/GenericRawResults;
.registers 22
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/lang/String;",
"[",
"Lcom/j256/ormlite/field/DataType;",
"[",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Lcom/j256/ormlite/dao/GenericRawResults<",
"[",
"Ljava/lang/Object;",
">;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
move-object/from16 v1, p0
move-object/from16 v10, p1
move-object/from16 v0, p4
const-string v11, "compiled statement"
.line 28
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "executing raw query for: {}"
move-object/from16 v12, p2
invoke-virtual {v2, v3, v12}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 29
array-length v2, v0
if-lez v2, :cond_1b
.line 30
sget-object v2, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v3, "query arguments: {}"
invoke-virtual {v2, v3, v0}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 31
:cond_1b
iget-object v2, v1, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v2}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v2
invoke-interface {v10, v2}, Lcom/j256/ormlite/support/ConnectionSource;->getReadOnlyConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v13
const/4 v14, 0x0
.line 32
:try_start_26
sget-object v6, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v7, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v8, -0x1
const/4 v9, 0x0
move-object v4, v13
move-object/from16 v5, p2
invoke-interface/range {v4 .. v9}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object v15
:try_end_33
.catchall {:try_start_26 .. :try_end_33} :catchall_54
.line 33
:try_start_33
invoke-direct {v1, v15, v0}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 34
new-instance v0, Lcom/j256/ormlite/stmt/RawResultsImpl;
const-class v6, [Ljava/lang/Object;
new-instance v8, Lcom/j256/ormlite/stmt/StatementExecutor$ObjectArrayRowMapper;
move-object/from16 v2, p3
invoke-direct {v8, v2}, Lcom/j256/ormlite/stmt/StatementExecutor$ObjectArrayRowMapper;-><init>([Lcom/j256/ormlite/field/DataType;)V
move-object v2, v0
move-object/from16 v3, p1
move-object v4, v13
move-object/from16 v5, p2
move-object v7, v15
move-object/from16 v9, p5
invoke-direct/range {v2 .. v9}, Lcom/j256/ormlite/stmt/RawResultsImpl;-><init>(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;Ljava/lang/Class;Lcom/j256/ormlite/support/CompiledStatement;Lcom/j256/ormlite/stmt/GenericRowMapper;Lcom/j256/ormlite/dao/ObjectCache;)V
:try_end_4d
.catchall {:try_start_33 .. :try_end_4d} :catchall_51
.line 35
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v0
:catchall_51
move-exception v0
move-object v14, v15
goto :goto_55
:catchall_54
move-exception v0
:goto_55
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
if-eqz v13, :cond_5d
.line 36
invoke-interface {v10, v13}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
:cond_5d
throw v0
.end method
.method public queryRaw(Lcom/j256/ormlite/support/ConnectionSource;Ljava/lang/String;[Ljava/lang/String;Lcom/j256/ormlite/dao/ObjectCache;)Lcom/j256/ormlite/dao/GenericRawResults;
.registers 21
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/ConnectionSource;",
"Ljava/lang/String;",
"[",
"Ljava/lang/String;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")",
"Lcom/j256/ormlite/dao/GenericRawResults<",
"[",
"Ljava/lang/String;",
">;"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
move-object/from16 v9, p0
move-object/from16 v10, p1
move-object/from16 v0, p3
const-string v11, "compiled statement"
.line 1
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "executing raw query for: {}"
move-object/from16 v12, p2
invoke-virtual {v1, v2, v12}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 2
array-length v1, v0
if-lez v1, :cond_1b
.line 3
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "query arguments: {}"
invoke-virtual {v1, v2, v0}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 4
:cond_1b
iget-object v1, v9, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-virtual {v1}, Lcom/j256/ormlite/table/TableInfo;->getTableName()Ljava/lang/String;
move-result-object v1
invoke-interface {v10, v1}, Lcom/j256/ormlite/support/ConnectionSource;->getReadOnlyConnection(Ljava/lang/String;)Lcom/j256/ormlite/support/DatabaseConnection;
move-result-object v13
const/4 v14, 0x0
.line 5
:try_start_26
sget-object v5, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->SELECT:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v6, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v7, -0x1
const/4 v8, 0x0
move-object v3, v13
move-object/from16 v4, p2
invoke-interface/range {v3 .. v8}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object v15
:try_end_33
.catchall {:try_start_26 .. :try_end_33} :catchall_4f
.line 6
:try_start_33
invoke-direct {v9, v15, v0}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 7
new-instance v0, Lcom/j256/ormlite/stmt/RawResultsImpl;
const-class v5, [Ljava/lang/String;
move-object v1, v0
move-object/from16 v2, p1
move-object v3, v13
move-object/from16 v4, p2
move-object v6, v15
move-object/from16 v7, p0
move-object/from16 v8, p4
invoke-direct/range {v1 .. v8}, Lcom/j256/ormlite/stmt/RawResultsImpl;-><init>(Lcom/j256/ormlite/support/ConnectionSource;Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;Ljava/lang/Class;Lcom/j256/ormlite/support/CompiledStatement;Lcom/j256/ormlite/stmt/GenericRowMapper;Lcom/j256/ormlite/dao/ObjectCache;)V
:try_end_48
.catchall {:try_start_33 .. :try_end_48} :catchall_4c
.line 8
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return-object v0
:catchall_4c
move-exception v0
move-object v14, v15
goto :goto_50
:catchall_4f
move-exception v0
:goto_50
invoke-static {v14, v11}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
if-eqz v13, :cond_58
.line 9
invoke-interface {v10, v13}, Lcom/j256/ormlite/support/ConnectionSource;->releaseConnection(Lcom/j256/ormlite/support/DatabaseConnection;)V
:cond_58
throw v0
.end method
.method public refresh(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TT;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedRefresh:Lcom/j256/ormlite/stmt/mapped/MappedRefresh;
if-nez v0, :cond_e
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1}, Lcom/j256/ormlite/stmt/mapped/MappedRefresh;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;)Lcom/j256/ormlite/stmt/mapped/MappedRefresh;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedRefresh:Lcom/j256/ormlite/stmt/mapped/MappedRefresh;
.line 3
:cond_e
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedRefresh:Lcom/j256/ormlite/stmt/mapped/MappedRefresh;
invoke-virtual {v0, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedRefresh;->executeRefresh(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
return p1
.end method
.method public update(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/PreparedUpdate;)I
.registers 5
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"Lcom/j256/ormlite/stmt/PreparedUpdate<",
"TT;>;)I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
.line 6
sget-object v1, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->UPDATE:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
invoke-interface {p2, p1, v1}, Lcom/j256/ormlite/stmt/PreparedUpdate;->compile(Lcom/j256/ormlite/support/DatabaseConnection;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
.line 7
:try_start_8
invoke-interface {p1}, Lcom/j256/ormlite/support/CompiledStatement;->runUpdate()I
move-result p2
.line 8
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz v1, :cond_23
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {v1}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object v1
check-cast v1, Ljava/lang/Boolean;
invoke-virtual {v1}, Ljava/lang/Boolean;->booleanValue()Z
move-result v1
if-nez v1, :cond_23
.line 9
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {v1}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:try_end_23
.catchall {:try_start_8 .. :try_end_23} :catchall_27
.line 10
:cond_23
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return p2
:catchall_27
move-exception p2
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method
.method public update(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 6
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TT;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedUpdate:Lcom/j256/ormlite/stmt/mapped/MappedUpdate;
if-nez v0, :cond_e
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1}, Lcom/j256/ormlite/stmt/mapped/MappedUpdate;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;)Lcom/j256/ormlite/stmt/mapped/MappedUpdate;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedUpdate:Lcom/j256/ormlite/stmt/mapped/MappedUpdate;
.line 3
:cond_e
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedUpdate:Lcom/j256/ormlite/stmt/mapped/MappedUpdate;
invoke-virtual {v0, p1, p2, p3}, Lcom/j256/ormlite/stmt/mapped/MappedUpdate;->update(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 4
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_2b
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_2b
.line 5
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_2b
return p1
.end method
.method public updateId(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
.registers 7
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lcom/j256/ormlite/support/DatabaseConnection;",
"TT;TID;",
"Lcom/j256/ormlite/dao/ObjectCache;",
")I"
}
.end annotation
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedUpdateId:Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;
if-nez v0, :cond_e
.line 2
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->databaseType:Lcom/j256/ormlite/db/DatabaseType;
iget-object v1, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->tableInfo:Lcom/j256/ormlite/table/TableInfo;
invoke-static {v0, v1}, Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;->build(Lcom/j256/ormlite/db/DatabaseType;Lcom/j256/ormlite/table/TableInfo;)Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;
move-result-object v0
iput-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedUpdateId:Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;
.line 3
:cond_e
iget-object v0, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->mappedUpdateId:Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;
invoke-virtual {v0, p1, p2, p3, p4}, Lcom/j256/ormlite/stmt/mapped/MappedUpdateId;->execute(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/Object;Ljava/lang/Object;Lcom/j256/ormlite/dao/ObjectCache;)I
move-result p1
.line 4
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
if-eqz p2, :cond_2b
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->localIsInBatchMode:Ljava/lang/ThreadLocal;
invoke-virtual {p2}, Ljava/lang/ThreadLocal;->get()Ljava/lang/Object;
move-result-object p2
check-cast p2, Ljava/lang/Boolean;
invoke-virtual {p2}, Ljava/lang/Boolean;->booleanValue()Z
move-result p2
if-nez p2, :cond_2b
.line 5
iget-object p2, p0, Lcom/j256/ormlite/stmt/StatementExecutor;->dao:Lcom/j256/ormlite/dao/Dao;
invoke-interface {p2}, Lcom/j256/ormlite/dao/Dao;->notifyChanges()V
:cond_2b
return p1
.end method
.method public updateRaw(Lcom/j256/ormlite/support/DatabaseConnection;Ljava/lang/String;[Ljava/lang/String;)I
.registers 13
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/sql/SQLException;
}
.end annotation
const-string v0, "compiled statement"
.line 1
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "running raw update statement: {}"
invoke-virtual {v1, v2, p2}, Lcom/j256/ormlite/logger/Logger;->debug(Ljava/lang/String;Ljava/lang/Object;)V
.line 2
array-length v1, p3
if-lez v1, :cond_13
.line 3
sget-object v1, Lcom/j256/ormlite/stmt/StatementExecutor;->logger:Lcom/j256/ormlite/logger/Logger;
const-string v2, "update arguments: {}"
invoke-virtual {v1, v2, p3}, Lcom/j256/ormlite/logger/Logger;->trace(Ljava/lang/String;Ljava/lang/Object;)V
.line 4
:cond_13
sget-object v5, Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;->UPDATE:Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;
sget-object v6, Lcom/j256/ormlite/stmt/StatementExecutor;->noFieldTypes:[Lcom/j256/ormlite/field/FieldType;
const/4 v7, -0x1
const/4 v8, 0x0
move-object v3, p1
move-object v4, p2
invoke-interface/range {v3 .. v8}, Lcom/j256/ormlite/support/DatabaseConnection;->compileStatement(Ljava/lang/String;Lcom/j256/ormlite/stmt/StatementBuilder$StatementType;[Lcom/j256/ormlite/field/FieldType;IZ)Lcom/j256/ormlite/support/CompiledStatement;
move-result-object p1
.line 5
:try_start_1f
invoke-direct {p0, p1, p3}, Lcom/j256/ormlite/stmt/StatementExecutor;->assignStatementArguments(Lcom/j256/ormlite/support/CompiledStatement;[Ljava/lang/String;)V
.line 6
invoke-interface {p1}, Lcom/j256/ormlite/support/CompiledStatement;->runUpdate()I
move-result p2
:try_end_26
.catchall {:try_start_1f .. :try_end_26} :catchall_2a
.line 7
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
return p2
:catchall_2a
move-exception p2
invoke-static {p1, v0}, Lcom/j256/ormlite/misc/IOUtils;->closeThrowSqlException(Ljava/io/Closeable;Ljava/lang/String;)V
throw p2
.end method