Knowing if and which shared drives are enabled

Hallo,

do you know if there is a way to find out programatically or by using the command line, if and which shared drives are enabled?
Thanks