api: refactor common code to get classname for an api in ApiServer
api: refactor common code to get classname for an api in ApiServer

- Refactor common code to get classname from apiname
- Fix search mechanism within api access checker adapter to:
  * check permissions
  * get class name for an apiname

Signed-off-by: Rohit Yadav <0fa72ca37c4b5fa62675187ce32ea6c9f842fd52@apache.org>

jcshen007/cloudstack,wido/cloudstack,resmo/cloudstack,jcshen007/cloudstack,jcshen007/cloudstack,jcshen007/cloudstack,wido/cloudstack,wido/cloudstack,resmo/cloudstack,resmo/cloudstack,GabrielBrascher/cloudstack,resmo/cloudstack,DaanHoogland/cloudstack,resmo/cloudstack,mufaddalq/cloudstack-datera-driver,GabrielBrascher/cloudstack,GabrielBrascher/cloudstack,mufaddalq/cloudstack-datera-driver,GabrielBrascher/cloudstack,jcshen007/cloudstack,jcshen007/cloudstack,mufaddalq/cloudstack-datera-driver,DaanHoogland/cloudstack,GabrielBrascher/cloudstack,GabrielBrascher/cloudstack,wido/cloudstack,resmo/cloudstack,mufaddalq/cloudstack-datera-driver,resmo/cloudstack,DaanHoogland/cloudstack,GabrielBrascher/cloudstack,wido/cloudstack,DaanHoogland/cloudstack,mufaddalq/cloudstack-datera-driver,mufaddalq/cloudstack-datera-driver,DaanHoogland/cloudstack,wido/cloudstack,jcshen007/cloudstack,DaanHoogland/cloudstack,DaanHoogland/cloudstack,wido/cloudstack