Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark some internal sealed trait @DoNotInherit #1270

Open
He-Pin opened this issue Apr 8, 2024 · 3 comments
Open

Mark some internal sealed trait @DoNotInherit #1270

He-Pin opened this issue Apr 8, 2024 · 3 comments

Comments

@He-Pin
Copy link
Member

He-Pin commented Apr 8, 2024

There are classes is not marked with @DoNotInherent, then Java user may extends that classes. We should mark it with @DoNotInherent.

And there are some classes should be annotated with @InternalApi.

refs: apache/pekko-connectors#588

@He-Pin He-Pin changed the title Mark seald trait @DoNotInherent Mark some internal seald trait @DoNotInherent Apr 8, 2024
@mdedetrich
Copy link
Contributor

Is @DoNotInherent necessary if the class is final, that is already implied?

Typically @ DoNotInherent is used for classes which can be extended but only for private cases

@He-Pin
Copy link
Member Author

He-Pin commented Apr 8, 2024

no, I mean we should mark on sealed trait and sealed abstract class

@mdedetrich
Copy link
Contributor

no, I mean we should mark on sealed trait and sealed abstract class

That makes perfect sense, :+1 from me

@pjfanning pjfanning changed the title Mark some internal seald trait @DoNotInherent Mark some internal sealed trait @DoNotInherit Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants