Maybe use in combination with an enumeration.
Like ...
Code:
public Test(String catID, String name, CatNameKind nameKind)
{
_catID = catID;
switch (nameKind){
case CatNameKind.Normal:
_catName = name;
break;
case CatNameKind.Sub:
_subCatName = name;
break;
case CatNameKind.Mother:
_motherCatName = name;
break;
}
}
In combination with an enumeration like this ...
Code:
public enum CatNameKind{
Normal,
Sub,
Mother
}
Creation gets easy like:
Code:
Test t = new Test("007XV", "KlaartjeTheCat", CatNameKind.Normal);
I hope it's a useful idea