Android Question An Internal Library Supersedes an Additional Library With the Same Name

Mahares

Expert
Licensed User
Longtime User
Is there an easy way to determine which libraries have become internal and are no longer needed in the additional library folder without having to print both folders and make a comparison, so the additional ones can be removed. One comes to mind is the XUI. It was external, now it is internal. There are others. I think the external library does not do any harm since the internal one gets priority, but as part of the clean-up there should only be one place for any given library.
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
Run this code in B4J:
B4X:
Dim InternalFolder As String = "c:\program files (x86)\anywhere software\basic4android\libraries"
Dim AdditionalFolder As String = "C:\Users\H\Documents\AdditionalLibraries"
Dim m As Map
m.Initialize
For Each f As String In File.ListFiles(InternalFolder)
   f = f.ToLowerCase
   If f.EndsWith(".xml") Or f.EndsWith(".jar") Then
       m.Put(f, "")
   End If
Next
For Each f As String In File.ListFiles(AdditionalFolder)
   f = f.ToLowerCase
   If m.ContainsKey(f) Then
       Log("Duplicate library: " & f)
   End If
Next
 
Upvote 0
Top