![]() |
|
Google LibPhonenumber import issues - Printable Version +- Atozed Forums (https://www.atozed.com/forums) +-- Forum: Atozed Software (https://www.atozed.com/forums/forum-1.html) +--- Forum: CrossTalk (https://www.atozed.com/forums/forum-2.html) +---- Forum: CrossTalk General Discussion (https://www.atozed.com/forums/forum-7.html) +---- Thread: Google LibPhonenumber import issues (/thread-3848.html) |
Google LibPhonenumber import issues - cpstevenc - 01-31-2024 Greetings.. using latest CrossTalk demo and Delphi 11.3 for win32 DCL: 2.0.32 NET: 533320 Middle (x86): 2.0.32 Right: 2.0.32 UI: 2.0.32 I am messing around with Google LibPhonenumber for C# ( For life of me can't get CPP version to compile so gave up. ) Originally I found this @ landrix/LibPhonenumber-for-Delphi: Delphi-wrapper for the .NET port of Google's libphonenumber for parsing, formatting and validating international phone numbers. (github.com) And for most part it works. Looks like he wrote a middle man DLL type deal to go between Delphi and the .NET DLL ... but only covers 2 calls of the over all library. Limited, but does work. Then I remembered CrossTalk and gave it A whirl. It created a NET.PhoneNumbers.pas file But it is missing a few things....? Unreferenced <--- not sure? Code: PhoneNumberUtil = class(TCTBaseObject)RegexOptions <-- only used once... but I think? I just need to import some other .NET library to include this regex engine maybe? Code: PhoneRegex = class(TCTBaseObject)TCTObject <--- Atozed.CrossTalk.BaseObject has no mention of this? TypeNET <--- this i get as Type is a reserved word... so it must create TypeNet ... but i figure this is to be something else really in the end? Pretty much every object has this "Equals" call that references TCTObject the and GetType:TypeNet; Code: AreaCodeMapStorageStrategy = class(TCTBaseObject)For now I just did this to get by Code: RegexOptions = classAnd it compiles... And it runs.... Code: Uses NET.PhoneNumbers, ...I imported a small DLL I wrote in C# ... Add/Subtract kind of deal. Just to play with. And it too created references to TCTObject the and GetType:TypeNet; This the win32 .NET DLL I imported https://github.com/landrix/LibPhonenumber-for-Delphi/blob/main/Win32/PhoneNumbers.dll |