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

codegen project is incomplete / non-functional #2007

Closed
Marcono1234 opened this issue Nov 2, 2021 · 5 comments
Closed

codegen project is incomplete / non-functional #2007

Marcono1234 opened this issue Nov 2, 2021 · 5 comments
Labels

Comments

@Marcono1234
Copy link
Collaborator

It looks like the codegen project is incomplete. The only thing it does is write an empty class, see:

writer.addPackage(CodeGen.getPackage(type).getQualifiedName().toString());
writer.beginType(typeAdapterName, "class", FINAL, null);
writer.endType();

For example, the output for the Order test class is just:

package com.google.gson.codegen.functional;
final class Order$TypeAdapter {
}

Should the project be removed, or should its functionality be implemented eventually?

@eamonnmcmanus
Copy link
Member

I think I would be in favour of deleting it. The code is 9 years old. It seems very half-baked, has no documentation, and has what appears to be a copy of a very old version of JavaPoet. There might be interest in some sort of code-generating solution, but if so I think it would be better built with modern tools, including the latest JavaPoet.

Perhaps @inder123 wants to weigh in, though?

@inder123
Copy link
Collaborator

inder123 commented Nov 2, 2021

proto has users. May be best to leave it as is?

@eamonnmcmanus
Copy link
Member

Yes, sorry, the question was about the codegen project, not the proto project.

@Marcono1234
Copy link
Collaborator Author

Has been resolved by #2099

@NBXXF
Copy link

NBXXF commented Dec 5, 2023

you can use https://github.com/NBXXF/gson_plugin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants