C# Class Achamenes.ID3.StandardGenreManager

This class implements genre management for the standard and extended genre codes as defined in Appendix A of the formal ID3 v2.3 documentation.
Inheritance: IGenreManager
Show file Open project: sahands/a-id3 Class Usage Examples

Public Methods

Method Description
GetGenreCode ( string genreName ) : byte

Returns the genre code of the specified genre name.

The search is case-insensitive.

GetGenreList ( ) : string[]

Returns a copy of the list of standard genre names.

GetGenreName ( byte code ) : string

Returns the name of genre corresponding with the given code.

TranslateToID3Friendly ( string genre ) : string

Translates a user entered genre name to a string that can be written to an ID3 tag.

TranslateToUserFriendly ( string genre ) : string

Translates a genre string as found in an ID3 tag to a user friendly representative.

Private Methods

Method Description
LoadGenereDictionary ( ) : void

Method Details

GetGenreCode() public method

Returns the genre code of the specified genre name.
The search is case-insensitive.
public GetGenreCode ( string genreName ) : byte
genreName string The name of the genre.
return byte

GetGenreList() public static method

Returns a copy of the list of standard genre names.
public static GetGenreList ( ) : string[]
return string[]

GetGenreName() public method

Returns the name of genre corresponding with the given code.
public GetGenreName ( byte code ) : string
code byte The code of the genre.
return string

TranslateToID3Friendly() public method

Translates a user entered genre name to a string that can be written to an ID3 tag.
public TranslateToID3Friendly ( string genre ) : string
genre string The string representing the genre as entered by the user.
return string

TranslateToUserFriendly() public method

Translates a genre string as found in an ID3 tag to a user friendly representative.
public TranslateToUserFriendly ( string genre ) : string
genre string The genre name as found in the ID3 tag.
return string