Explorar o código

add lookupContactIdByAddress dcContext wrapper method

cyberta %!s(int64=4) %!d(string=hai) anos
pai
achega
9b9bae8cee
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      DcCore/DcCore/DC/Wrapper.swift

+ 4 - 0
DcCore/DcCore/DC/Wrapper.swift

@@ -188,6 +188,10 @@ public class DcContext {
         dc_add_address_book(contextPointer, contactString)
     }
 
+    public func lookupContactIdByAddress(_ address: String) -> Int {
+        return Int(dc_lookup_contact_id_by_addr(contextPointer, addr))
+    }
+
     public func getChat(chatId: Int) -> DcChat {
         let chatPointer = dc_get_chat(contextPointer, UInt32(chatId))
         return DcChat(chatPointer: chatPointer)