-
Notifications
You must be signed in to change notification settings - Fork 454
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
80fb145
commit 0c84085
Showing
8 changed files
with
157 additions
and
49 deletions.
There are no files selected for viewing
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
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
14 changes: 14 additions & 0 deletions
14
critter/core/src/test/kotlin/dev/morphia/critter/sources/DummyEntityAgeAccessorModel.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,14 @@ | ||
package dev.morphia.critter.sources; | ||
|
||
import org.bson.codecs.pojo.PropertyAccessor; | ||
|
||
public class DummyEntityAgeAccessorModel implements PropertyAccessor<Integer> { | ||
@Override | ||
public <S> Integer get(S entity) { | ||
return ((DummyEntity) entity).__readAgeSample(); | ||
} | ||
|
||
public <S> void set(S entity, Integer value) { | ||
((DummyEntity) entity).__writeAgeSample(value); | ||
} | ||
} |
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
10 changes: 10 additions & 0 deletions
10
critter/core/src/test/kotlin/dev/morphia/critter/sources/KotlinDummyEntity.kt
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,10 @@ | ||
package dev.morphia.critter.sources | ||
|
||
class KotlinDummyEntity { | ||
private var name = "DummyEntity" | ||
private var age = 21 | ||
|
||
override fun toString(): String { | ||
return "KotlinDummyEntity(name='$name', age=$age)" | ||
} | ||
} |