I hope you can help me, I already researched my case but didn't found a good answer. I want to compare the content of a variable with the names of all existing resources (if possible only with drawable resources).
The question in short: How to compare the String content of an variable with a list of all resource names, preferential only with drawable resources? Or in other words: How to get a list (containing Strings) of all resource names, preferential only drawable resources?
The Case: I want to display a symbol based on a given type. This type is retrieved from a SQLite Database. There are many symbols stored as a drawable resource, they all are named like on of the possible types. For every stored type in the database I want to display the fitting symbol in a list. The equality should be find out through a comparison (via the contains method) between the variable "type" and a list containing the names of all (drawable) resources.
Example: In the database are types named "A", "B" and "C". In the drawable resources folder are graphics with the name "A", "BX" and "S". The comparison should lead to the case, that in the list only type "A" is connected with the fitting drawable symbol "A". Type "B" and "C" have no likely named drawable resources and thus shouldn't display any symbol.
I hope you understood my question and thank you in advanced for your help.