Geodatabase.getPath() in Quartz?

671
7
07-27-2017 01:29 PM
by Anonymous User
Not applicable

I am noticing that there is no longer the option in Quartz to get the path of a Geodatatabase via Geodatabase.getPath().  This is some very useful functionality to keep track of where the active GDB in a mapview is located on the file system.  How would I be able to pull this information in Quartz?

0 Kudos
7 Replies
AlexanderNohe1
Occasional Contributor III

Few questions:

How are you instantiating the Geodatabase object?

Are you using more than one Geodatabase at a time?

0 Kudos
by Anonymous User
Not applicable

Hi Alex, Yes we have situations when pointed at a webmap for download where we have an array list of geodatabases.  Each GDB used by the app has a subdirectory that incorporates a guid value in the naming convention of the sub directory.  Thus the need to pull that information from the GDB.  Was hoping to avoid the extra hassle of having to store this information in a separate file.  

syncGDBFromGDBArray is an integer of course.

public static final ArrayList<Geodatabase> localGDBs = new ArrayList<>();

String localGdbFilePath = localGDBs.get(syncGDBFromGDBArray).getPath();
0 Kudos
by Anonymous User
Not applicable

OK I think this might work, although I am not at a point where I can build this monstrous Android Studio Project.  Alex can you verify?

When I use toString() in 10.2.9 it does give me the path as part of the returned string...

String localGdbFilePath = localGDBs.get(syncGDBFromGDBArray).toString();

in 10.2.9 this returns...

Geodatabase [gdbPath=/storage/9016-4EF8/Android/data/gov.s1.s1mobile/Edit_Data/ParkFeatures_c50477c5-6bf8-4763-a809-cbdf56580edf/ParkFeatures.geodatabase]

Does this return the same value in Quartz?
0 Kudos
AlexanderNohe1
Occasional Contributor III

When I get a chance soon, I can try to test.

Thanks,

Alexander

0 Kudos
AlexanderNohe1
Occasional Contributor III

No, it returns :
com.esri.arcgisruntime.data.Geodatabase@2f176e90

0 Kudos
by Anonymous User
Not applicable

Hmm any thoughts on how this could be accomplished?

0 Kudos
AlexanderNohe1
Occasional Contributor III

Can you go a little more into your use case?

0 Kudos