commandlineparser / commandlineparser/commandline

Enum with 0 value not shown on Example

オープン
#379 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る
bug good first issue
主要言語
C#
スター
4.8k
フォーク
478
PR マージ指標
30日以内にマージされた PR はありません

説明

public class MyOption
{
[Option('t', "type", Required = true, HelpText = "My entity")]
public EntityType MyEntityType { get; set; }
public enum MyEntityType
{
X0, // Example for X0 is empty. If change this line to X0 =1, everything is ok
X1,
X2
}

[Usage(ApplicationAlias = "...")]
public static IEnumerable Examples
{
get
{
foreach (EntityType entityType in Enum.GetValues(typeof(EntityType)))
{
yield return new Example(entityType.ToString(), new MyOption { MyEntityType = entityType});
}
}
}
}

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。