-
Notifications
You must be signed in to change notification settings - Fork 182
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #498 from pushtorefresh/storio-sqlite-annotations-…
…blob Add support for byte[] into StorIOSQLite annotation processor
- Loading branch information
Showing
5 changed files
with
91 additions
and
19 deletions.
There are no files selected for viewing
54 changes: 54 additions & 0 deletions
54
...mple-app/src/main/java/com/pushtorefresh/storio/sample/db/entities/AllSupportedTypes.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
package com.pushtorefresh.storio.sample.db.entities; | ||
|
||
import com.pushtorefresh.storio.sqlite.annotations.StorIOSQLiteColumn; | ||
import com.pushtorefresh.storio.sqlite.annotations.StorIOSQLiteType; | ||
|
||
/** | ||
* Just a sample entity with all supported types of type mapping via annotation processor. | ||
*/ | ||
@StorIOSQLiteType(table = "there_is_no_such_table") | ||
public class AllSupportedTypes { | ||
|
||
@StorIOSQLiteColumn(name = "some_boolean") | ||
boolean someBoolean; | ||
|
||
@StorIOSQLiteColumn(name = "some_boolean_object") | ||
Boolean someBooleanObject; | ||
|
||
@StorIOSQLiteColumn(name = "some_short") | ||
short someShort; | ||
|
||
@StorIOSQLiteColumn(name = "some_short_object") | ||
Short someShortObject; | ||
|
||
@StorIOSQLiteColumn(name = "some_integer", key = true) // One field should be key | ||
int someInteger; | ||
|
||
@StorIOSQLiteColumn(name = "some_integer_object") | ||
Integer someIntegerObject; | ||
|
||
@StorIOSQLiteColumn(name = "some_long") | ||
long someLong; | ||
|
||
@StorIOSQLiteColumn(name = "some_long_object") | ||
Long someLongObject; | ||
|
||
@StorIOSQLiteColumn(name = "some_float") | ||
float someFloat; | ||
|
||
@StorIOSQLiteColumn(name = "some_float_object") | ||
Float someFloatObject; | ||
|
||
@StorIOSQLiteColumn(name = "some_double") | ||
double someDouble; | ||
|
||
@StorIOSQLiteColumn(name = "some_double_object") | ||
Double someDoubleObject; | ||
|
||
@StorIOSQLiteColumn(name = "some_string") | ||
String someString; | ||
|
||
@StorIOSQLiteColumn(name = "some_byte_array") | ||
byte[] someByteArray; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters