I have a class with constant string routes:
public class Routes
{
public const string Route1 = "api/customers";
}
And a WebApi controller class with Route attribute:
public class CustomerController : ApiController
{
[Route(Routes.Route1)]
public IList<Customer> GetCustomers()
{..}
}
I need to get a string value of constant from attribute using EnvDTE.
I'm able to receive CodeAttribute2 object and then value of CodeAttributeArgument but its Value just "Routes.Route1".
How to navigate to Route type and then to Route1 constant?