add kdoc for Post.kt
This commit is contained in:
parent
f241ed55e0
commit
febf442faa
@ -9,10 +9,17 @@ typealias PostId = String
|
||||
typealias PostContents = List<Content>
|
||||
typealias RegisteredPostContents = List<RegisteredContent>
|
||||
|
||||
/**
|
||||
* Base interface for creating of new post. Usually, it is just [SimplePost] instance
|
||||
*/
|
||||
interface Post {
|
||||
val content: PostContents
|
||||
}
|
||||
|
||||
/**
|
||||
* Root entity of whole system. Can be retrieved from [com.insanusmokrassar.postssystem.core.api.ReadPostsAPI] by
|
||||
* getting and created in [com.insanusmokrassar.postssystem.core.api.WritePostsAPI] by inserting of [Post] instance
|
||||
*/
|
||||
interface RegisteredPost : Post {
|
||||
val id: PostId
|
||||
|
||||
@ -22,10 +29,17 @@ interface RegisteredPost : Post {
|
||||
val modificationDate: DateTime
|
||||
}
|
||||
|
||||
/**
|
||||
* Base and currently (1st Nov 2019) single realisation of [Post]. There is [SimpleRegisteredPost] which is technically
|
||||
* is [Post] too, but it is not direct [Post] realisation
|
||||
*/
|
||||
data class SimplePost(
|
||||
override val content: PostContents
|
||||
) : Post
|
||||
|
||||
/**
|
||||
* Base and currently (1st Nov 2019) single realisation of [RegisteredPost]
|
||||
*/
|
||||
data class SimpleRegisteredPost(
|
||||
override val id: PostId,
|
||||
override val content: RegisteredPostContents,
|
||||
|
Loading…
Reference in New Issue
Block a user