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

Vehicle: add start/stop setter #13056

Closed
andig opened this issue Mar 20, 2024 · 4 comments · Fixed by #13119
Closed

Vehicle: add start/stop setter #13056

andig opened this issue Mar 20, 2024 · 4 comments · Fixed by #13119
Assignees
Labels
backlog Things to do later

Comments

@andig
Copy link
Member

andig commented Mar 20, 2024

Refs #13055 (comment)

/cc @GrimmiMeloni re api.VehicleChargeController

@andig andig added the backlog Things to do later label Mar 20, 2024
@andig andig self-assigned this Mar 20, 2024
@Adminius
Copy link
Contributor

FinishTime? ;)

@GrimmiMeloni
Copy link
Collaborator

GrimmiMeloni commented Mar 22, 2024

I‘m actively working on the required generator enhancement.

@andig
Copy link
Member Author

andig commented Mar 22, 2024

@GrimmiMeloni aktuell generieren wir ja aus sowas:

-t "api.SocLimiter,GetLimitSoc,func() (float64, error)"

Wenn wir stattdessen in der Lage wären, alle Methoden eines Interfaces (auch falls >1) auszulesen würde das dann so aussehen:

-t api.SocLimiter

Sowohl Methode als auch Signatur würden/müssten dann per Reflect oder AST ermittelt und an den Generator übergeben werden. Wäre das denkbar? Würde auch viele/alle go:generate Statements deutlich vereinfachen, auch ohne dass Typsicherheit leiden würde.

@GrimmiMeloni
Copy link
Collaborator

Hab ich auch schon überlegt. Aktuell bin ich erstmal am „backend“. Die Daten in den Strukturen sind bereits sauber, ich muss noch am Template feilen. Wenn das läuft wäre Deine Idee aber auch bei mir auf der Wishlist, denn einzelne Funktionen aus einem Interface allein lassen sich dann sowieso nicht anbinden. Es müssen dann immer alle angegeben werden. Die Generator Zeilen werden dann schnell länger als die Würmer auf Arrakis.

@andig andig changed the title Vehicle: add start/stop setter, tagetsoc getter Vehicle: add start/stop setter Mar 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backlog Things to do later
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants