Skip to content

Commit

Permalink
open fun getAttributes()
Browse files Browse the repository at this point in the history
  • Loading branch information
michaellif committed Mar 26, 2021
1 parent fe52960 commit 8260109
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ abstract class AbstractAggregate(private val aggregateName: String) : Aggregate
return builder.toString()
}

private fun getAttributes(): String {
open fun getAttributes(): String {
return this::class.declaredMemberProperties.filter { it.visibility == KVisibility.PUBLIC }
.joinToString(prefix = "[", postfix = "]") { "${it.name}=${it.getter.call(this)}" }
}
Expand All @@ -106,6 +106,7 @@ abstract class AbstractAggregate(private val aggregateName: String) : Aggregate
fun nextRandomInt(seed: Int, bound: Int): Int {
return Random(31 * randomSeed + seed).nextInt(bound)
}

}


0 comments on commit 8260109

Please sign in to comment.