Hi folks!
Sometimes, when designing a class method and feeding it with more and more useful features, very soon the number of parameters can reach 10 and even more.
It becomes pretty difficult for users of useful methods to remember the position of the important parameter, and it is very easy to misuse the position and transfer the wrong value to the wrong parameter.
Here is an example of such a method (I asked GPT to create a method with 20 params):
ClassMethod GenerateReportWith20Params(
pTitle As %String = "",
pAuthor As %String = "",
pDate As %String = "",
pCompany As %String = "",
pDepartment As %String = "",
pVersion As %String = "1.0",
pFormat As %String = "pdf",
pIncludeCharts As %Boolean = 1,
pIncludeSummary As %Boolean = 1,
pIncludeAppendix As %Boolean = 0,
pConfidentiality As %String = "Public",
pLanguage As %String = "en",
pReviewers As %String = "",
pApprover As %String = "",
pLogoPath As %String = "",
pWatermarkText As %String = "",
pColorScheme As %String = "default",
pPageSize As %String = "A4",
pOrientation As %String = "Portrait",
pOutputPath As %String = "report.pdf"
) As %Status
{
}