I need to take a given drawable name from a cloud DB and check to see if a matching Drawable exists in the local package. If it doesn't, I need to create a local copy of the image for use so I'm not constantly accessing the remote resource. What's the best way to do this? I can access the database, do the SQL, all that stuff. I just need to know how to A) check the local package for the existence of a Drawable called (for instance) 'icon,' and if it doesn't exist locally I need to know how to create and store a local copy (via HTTPstream maybe?).
How to check for a local Drawable, and lacking one, how to make one from a remote resource?
1.8k Views Asked by cschryer At
1
There are 1 best solutions below
Related Questions in ANDROID
- Delay in loading Html Page(WebView) from assets folder in real android device
- MPAndroidChart method setWordWrapEnabled() not found
- Designing a 'new post' android activity
- Android :EditText inside ListView always update first item in the listview
- Android: Transferring Data via ContentIntent
- Wrong xml being inflated android
- AsyncTask Class
- Unable to receive extras in Android Intent
- Website zoomed out on Android default browser
- Square FloatingActionButton with Android Design Library
- Google Maps API Re-size
- Push toolbar content below statusbar
- Android FragmentPagerAdapter Circular listview
- Layout not shifting up when keyboard is open
- auDIO_OUTPUT_FLAG_FAST denied by client can't connect to localhost
Related Questions in SQLITE
- How to insert values into Android SQLite Database?
- Inserting and returning autoidentity in SQLite3
- sqlite3 select statement fails with "parameters are of unsupported type
- Android database query not returning any results
- No such column error when column does exist
- Can't insert " character into Sqlite DB [Objective-C]
- How do I Insert a Previously Created SQLite Database into a Xamarin.Android App?
- Clearing database for emulator app so it acts like being run for the first time?
- SQLite UPDATE statement updates all row in table
- ActiveResource::ResourceNotFound: Failed. Response code = 404. Response message = Not Found
- Syntax error in rails database query
- Deleting and Updating values from a cusrsor adapter
- restrict sqlite-wal and sqlite-shm from icloud backup
- Recieveing Null Pointer Exception when trying to retrieve data from SQL database to listview android
- Scraping blog and saving date to database causes DateError: unknown date format
Related Questions in DRAWABLE
- Image in drawable but still getting error
- Android Studio missing drawable Folder
- Using images saved in drawable in an app - Android
- Android Selector Drawable doesnt work with attributes
- Cannot reference from XML to custom @drawable resource in Android studio
- Stretch drawable in the layer-list
- Change layout of EditText on state "selected"
- Customizing the android seekbar thumb
- DrawableCompat tinting does not work on pre-Lollipop
- How to Send Drawable as a parameter to a function
- Android/xml drawable button, image resizing
- How to change the checkbox drawable of a ListView?
- Android: How can i convert a Bitmap array to Int array?
- DrawableCompat.unwrap is not working pre Lollipop
- Android Button Drawable Tint
Related Questions in HTTP-STREAMING
- On WP8.1 ONLY: cannot read more than 65536 bytes off an HTTP Stream
- Error being thrown by ffmpeg and ffserver, not getting a stream
- Http Media Streaming Server
- Implement http streaming client on android
- Large file download with Play framework
- Docker swarm - docker.sock slowdown
- Which is the best Flash H.264 HTTP Streaming method?
- Secure pseudo-streaming flv files
- How to handle chunked/streamed response data using Zend_Http_Client?
- EventMachine and Twitter streaming API
- How to optimize the FFMPEG h264/aac conversion while generating HLS segments too
- Implementing thread per request in HTTP Streaming servlet
- VideoJS: Excessive main segment downloading detected errors during a live event
- VideoJS: segment duration issue in HLS stream
- VideoJS: fetches old segments during a live stream
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
1: Check for your drawable like this:
2: You can't put a downloaded drawable inside drawableFolder. But you can download it to res/raw or to the sdcard. Note to check that location also if you already downloaded this particular drawable.