Skip to content

Implement a way to expose the display names for enum values #157

@kevbite

Description

@kevbite

Companies House have a list of enum values to their display name representation. It'd be good if the following was possible:

var result = await client.GetCompanyProfileAsync("10440441");

// England/Wales
var displayName = result.Data.GetDisplayName(x =>x.Jurisdiction);
Console.WriteLine(displayName);

We could do this by having [DisplayName] attributes on the enum values with the corresponding values in the yaml file (https://raw.githubusercontent.com/companieshouse/api-enumerations/master/constants.yml).

Follow up enhancement from issue #156

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions