FamilyManager

interface FamilyManager

Functions

Link copied to clipboard
abstract suspend fun createFamily(familyName: String, isOpened: Boolean = false): Family

Create family.

Link copied to clipboard
abstract fun createFamilyFlow(): Flow<Family?>
Link copied to clipboard
Link copied to clipboard
abstract suspend fun deleteFamily(familyId: String)

Delete family by familyId.

Link copied to clipboard
abstract suspend fun deleteFamilyMember(familyId: String, memberId: String)

Delete family member by familyId and memberId.

Link copied to clipboard
abstract suspend fun editFamily(familyId: String, familyName: String, isOpened: Boolean): Family

Edit family. The method allows you to change the family familyName with familyId and its isOpened modifier.

Link copied to clipboard
abstract suspend fun editFamilyMember(familyId: String, memberId: String, newMemberName: String): FamilyMember

Edit family member method.

Link copied to clipboard
abstract suspend fun fetch()

Fetch actual family and members info from backend.

Link copied to clipboard
abstract suspend fun inviteIntoFamily(familyId: String, phoneOrMail: String)

Send invitation to user with phoneOrMail into family with familyId.

Link copied to clipboard
abstract suspend fun joinToFamily(inviteHash: String, memberName: String)

Join to family by inviteHash with memberName.