translate rc to string

Hi

Maybe you can suggest a nicer way to do the following:

    RET_STR=$(echo ${RET} | sed -e 's/0/Object is not mapped/' \
        -e 's/1/Operation Internal Error/' \
        -e 's/2/Operation Invalid Arguments/' \
        -e 's/3/Object is mapped/' \
        -e 's/4/Path not found/')

Maybe something like this ?

case "${RET}" in
 0) 
         RET_STR="Object is not mapped";;
 1) 
         RET_STR="Operation Internal Error";;
 2) 
         RET_STR="Operation Invalid Arguments";;
 3) 
         RET_STR="Object is mapped";;
 4) 
         RET_STR="Path not found";;

esac

yes, that's the obvious way.. I preferred mine.
But still wonder if there's some better way

local RET_ARR=("Object is not mapped" "Operation Internal Error" "Operation Invalid Arguments" "Object is mapped" "Path not found")
...
echo "bla bla.. ret is [${RET}] - ${RET_ARR[${RET}]}"