<lambda>null1 import androidx.room.RoomDatabase
2 import androidx.room.util.getColumnIndexOrThrow
3 import androidx.room.util.performBlocking
4 import androidx.sqlite.SQLiteStatement
5 import javax.`annotation`.processing.Generated
6 import kotlin.Array
7 import kotlin.Int
8 import kotlin.Long
9 import kotlin.LongArray
10 import kotlin.Short
11 import kotlin.ShortArray
12 import kotlin.String
13 import kotlin.Suppress
14 import kotlin.collections.List
15 import kotlin.collections.MutableList
16 import kotlin.collections.mutableListOf
17 import kotlin.reflect.KClass
18 
19 @Generated(value = ["androidx.room.RoomProcessor"])
20 @Suppress(names = ["UNCHECKED_CAST", "DEPRECATION", "REDUNDANT_PROJECTION", "REMOVAL"])
21 public class MyDao_Impl(
22   __db: RoomDatabase,
23 ) : MyDao {
24   private val __db: RoomDatabase
25   init {
26     this.__db = __db
27   }
28 
29   public override fun queryOfArray(): Array<MyEntity> {
30     val _sql: String = "SELECT * FROM MyEntity"
31     return performBlocking(__db, true, false) { _connection ->
32       val _stmt: SQLiteStatement = _connection.prepare(_sql)
33       try {
34         val _columnIndexOfPk: Int = getColumnIndexOrThrow(_stmt, "pk")
35         val _columnIndexOfOther: Int = getColumnIndexOrThrow(_stmt, "other")
36         val _columnIndexOfOther2: Int = getColumnIndexOrThrow(_stmt, "other2")
37         val _listResult: MutableList<MyEntity> = mutableListOf()
38         while (_stmt.step()) {
39           val _item: MyEntity
40           val _tmpPk: Int
41           _tmpPk = _stmt.getLong(_columnIndexOfPk).toInt()
42           val _tmpOther: String
43           _tmpOther = _stmt.getText(_columnIndexOfOther)
44           val _tmpOther2: Long
45           _tmpOther2 = _stmt.getLong(_columnIndexOfOther2)
46           _item = MyEntity(_tmpPk,_tmpOther,_tmpOther2)
47           _listResult.add(_item)
48         }
49         val _result: Array<MyEntity> = _listResult.toTypedArray()
50         _result
51       } finally {
52         _stmt.close()
53       }
54     }
55   }
56 
57   public override fun queryOfNullableArray(): Array<MyEntity?> {
58     val _sql: String = "SELECT * FROM MyEntity"
59     return performBlocking(__db, true, false) { _connection ->
60       val _stmt: SQLiteStatement = _connection.prepare(_sql)
61       try {
62         val _columnIndexOfPk: Int = getColumnIndexOrThrow(_stmt, "pk")
63         val _columnIndexOfOther: Int = getColumnIndexOrThrow(_stmt, "other")
64         val _columnIndexOfOther2: Int = getColumnIndexOrThrow(_stmt, "other2")
65         val _listResult: MutableList<MyEntity> = mutableListOf()
66         while (_stmt.step()) {
67           val _item: MyEntity
68           val _tmpPk: Int
69           _tmpPk = _stmt.getLong(_columnIndexOfPk).toInt()
70           val _tmpOther: String
71           _tmpOther = _stmt.getText(_columnIndexOfOther)
72           val _tmpOther2: Long
73           _tmpOther2 = _stmt.getLong(_columnIndexOfOther2)
74           _item = MyEntity(_tmpPk,_tmpOther,_tmpOther2)
75           _listResult.add(_item)
76         }
77         val _result: Array<MyEntity?> = _listResult.toTypedArray()
78         _result
79       } finally {
80         _stmt.close()
81       }
82     }
83   }
84 
85   public override fun queryOfArrayWithLong(): Array<Long> {
86     val _sql: String = "SELECT pk FROM MyEntity"
87     return performBlocking(__db, true, false) { _connection ->
88       val _stmt: SQLiteStatement = _connection.prepare(_sql)
89       try {
90         val _listResult: MutableList<Long> = mutableListOf()
91         while (_stmt.step()) {
92           val _item: Long
93           _item = _stmt.getLong(0)
94           _listResult.add(_item)
95         }
96         val _result: Array<Long> = _listResult.toTypedArray()
97         _result
98       } finally {
99         _stmt.close()
100       }
101     }
102   }
103 
104   public override fun queryOfArrayWithNullableLong(): Array<Long?> {
105     val _sql: String = "SELECT pk FROM MyEntity"
106     return performBlocking(__db, true, false) { _connection ->
107       val _stmt: SQLiteStatement = _connection.prepare(_sql)
108       try {
109         val _listResult: MutableList<Long> = mutableListOf()
110         while (_stmt.step()) {
111           val _item: Long
112           _item = _stmt.getLong(0)
113           _listResult.add(_item)
114         }
115         val _result: Array<Long?> = _listResult.toTypedArray()
116         _result
117       } finally {
118         _stmt.close()
119       }
120     }
121   }
122 
123   public override fun queryOfLongArray(): LongArray {
124     val _sql: String = "SELECT pk FROM MyEntity"
125     return performBlocking(__db, true, false) { _connection ->
126       val _stmt: SQLiteStatement = _connection.prepare(_sql)
127       try {
128         val _listResult: MutableList<Long> = mutableListOf()
129         while (_stmt.step()) {
130           val _item: Long
131           _item = _stmt.getLong(0)
132           _listResult.add(_item)
133         }
134         val _result: LongArray = _listResult.toLongArray()
135         _result
136       } finally {
137         _stmt.close()
138       }
139     }
140   }
141 
142   public override fun queryOfShortArray(): ShortArray {
143     val _sql: String = "SELECT pk FROM MyEntity"
144     return performBlocking(__db, true, false) { _connection ->
145       val _stmt: SQLiteStatement = _connection.prepare(_sql)
146       try {
147         val _listResult: MutableList<Short> = mutableListOf()
148         while (_stmt.step()) {
149           val _item: Short
150           _item = _stmt.getLong(0).toShort()
151           _listResult.add(_item)
152         }
153         val _result: ShortArray = _listResult.toShortArray()
154         _result
155       } finally {
156         _stmt.close()
157       }
158     }
159   }
160 
161   public companion object {
162     public fun getRequiredConverters(): List<KClass<*>> = emptyList()
163   }
164 }
165