[Suggestion] Override Getter/Setter annotations #1026 - GitHub

文章推薦指數: 80 %
投票人數:10人

It would be nice if you would implement overriding getter/setter annotations. For example: @Getter public class Example { private int a; ... Skiptocontent {{message}} projectlombok / lombok Public Notifications Fork 2.1k Star 11k Code Issues 713 Pullrequests 11 Actions Wiki Security Insights More Code Issues Pullrequests Actions Wiki Security Insights Newissue Haveaquestionaboutthisproject?SignupforafreeGitHubaccounttoopenanissueandcontactitsmaintainersandthecommunity. Pickausername EmailAddress Password SignupforGitHub Byclicking“SignupforGitHub”,youagreetoourtermsofserviceand privacystatement.We’lloccasionallysendyouaccountrelatedemails. AlreadyonGitHub? Signin toyouraccount Jumptobottom [Suggestion]OverrideGetter/Setterannotations #1026 Closed delverdevopenedthisissue Feb15,2016 ·3comments Closed [Suggestion]OverrideGetter/Setterannotations #1026 delverdevopenedthisissue Feb15,2016 ·3comments Comments Copylink delverdev commented Feb15,2016 Itwouldbeniceifyouwouldimplementoverridinggetter/setterannotations.Forexample: @Getter publicclassExample{ privateinta; publicintgetA(){//overridetoavoidnpe returna<0?-1:a; } } Thetextwasupdatedsuccessfully,buttheseerrorswereencountered: Copylink Contributor Maaartinus commented Feb19,2016 Justdoit.Nogettergetsgeneratedifthere'salreadyonepresent. Youcanalsouse@Getter(AccessLevel.NONE)todisablethegenerationexplicitly. 👍 7 Sorry,somethingwentwrong. Copylink Author delverdev commented Feb20,2016 WellthenitisanissueofIntelliJIDEAplugin,whichwarnsmethatIcannothave@Getterandsimplegettertogether.Thankyoufortheanswer! Sorry,somethingwentwrong. Copylink Contributor Maaartinus commented Feb20,2016 AFAIK,thereshouldbenosuchwarningunlesstheannotationsurelygeneratesnogettersatall(afield-levelannotationtogetherwiththemanualgettershouldproduceawarning;aclass-levelannotationshouldnot). Sorry,somethingwentwrong. Rawi01 closedthis Feb21,2022 Signupforfree tojointhisconversationonGitHub. Alreadyhaveanaccount? Signintocomment Assignees Nooneassigned Labels Noneyet Projects Noneyet Milestone Nomilestone Linkedpullrequests Successfullymergingapullrequestmayclosethisissue. Noneyet 3participants Youcan’tperformthatactionatthistime. Yousignedinwithanothertaborwindow.Reloadtorefreshyoursession. Yousignedoutinanothertaborwindow.Reloadtorefreshyoursession.



請為這篇文章評分?