Questions tagged [codegen]

Use codegen for questions related to language features or tools which facilitate translating code between languages or creating code from metadata

References

242 questions
2
votes
0 answers

How to cancel request generated by Swagger Codegen

I am generating a lib with Swagger-codegen. The library I used was Volley. It doesn't seem the generated code has any way to cancel a request. Is there anyway to cancel the request through the generated code? As our api spec may change between each…
jarly
  • 231
  • 1
  • 4
  • 16
2
votes
0 answers

MATLAB to C codegen build error - input properties specification mismatch

I am trying to build a C/C++ static library from MATLAB code, but receive the following error: "Function 'application' input properties specification mismatch: expected 0 but found 2." Here is the function that I am trying to convert: function […
adub108
  • 21
  • 2
2
votes
1 answer

Jooq Maven Code-Gen: Cannot find symbol

on my current project i am using the jooq-framework code-generator plugin for maven. In my IDE (eclipse) everything is working fine but when trying to compile the project on the CI server or manually on cmd it fails with the message: "cannot find…
NeoP5
  • 611
  • 7
  • 19
2
votes
2 answers

How to use C library created by MATLAB Coder codegen in C program with emxArray arguments?

The C function (C static library) created by codegen takes an input argument of type const emxArray_uint32_T and return values of type emxArray_struct_T. As the type suggests, input is an array of uint32 and output is an array of struct. I'm not…
user39086
  • 175
  • 3
  • 10
2
votes
0 answers

EF6 DB first View Generation T4 Template for C#

I am currently in the process of updating EF5 to Ef6. We are using database first approach. in EF5 i have T4 template that generates mapping views for EF5. But for EF6 that template would not work. In VS 2013 -> Add new Item shows there is a…
Laksh
  • 151
  • 1
  • 4
2
votes
1 answer

Echoprint implementation

I'm implementing echoprint in my iOS 6 app but when I compile my project it gives me errors from Codegen. Undefined symbols for architecture i386: "Codegen::Codegen(float const*, unsigned int, int)", referenced from: …
Giova Fila
  • 21
  • 4
1
vote
1 answer

How to implement HashCode.Combine using SymbolEqualityComparer

After updating packages to .net7 in roslyn code generation project, has error RS1024 Use 'SymbolEqualityComparer' when comparing symbols for IEqualityComparer implementation of GetHashCode() public int GetHashCode([DisallowNull] TypeSymbolMetaType?…
1
vote
0 answers

Joda time openapi generation does not generated properly

joda-time joda-time 2.12.5 com.fasterxml.jackson.datatype
Nesly
  • 23
  • 5
1
vote
1 answer

The openapi-generator-maven-plugin does not generate @ExampleObject

I am using The openapi-generator-maven-plugin:6.4.0 to generate swagger code. I am able to access the APIs. But, in generated files @ExampleObject is not present. Also, in Swagger UI I am unable to see the examples specified in inputSpec. Please…
Ankitha J
  • 124
  • 1
  • 5
1
vote
0 answers

How to define custom response interface for GraphQL Query resolver?

How can I tell my Query resolver that the type it is returning does not need to match my GraphQL schema type since the data is going to be formatted by my type's custom resolvers? I am using codegen with GraphQL to generate my schema and type…
Stretch0
  • 8,362
  • 13
  • 71
  • 133
1
vote
0 answers

How to generate test with playwright and codegen from a docker container?

I'm using their standard image mcr.microsoft.com/playwright:v1.28.1-focal. When trying to launch the command yarn playwright codegen wikipedia.org from my docker container (for the sake of an example) I'm getting the following error: Looks like you…
1
vote
0 answers

How to use custom class in the swagger API

In my previous post How to accept multiple query parameters with different parameter name in one class I learned about passing the query parameters, and I also achieved it But now the problem is I am in a swagger setup where I use codegen for…
Vaibhav Jain
  • 61
  • 1
  • 6
1
vote
1 answer

How to accept multiple query parameters with different parameter name in one class

Consider a use case where I have a URL like /api/v1?credentials="test"&age=20&gender=male Now how can I have 2 different type of cases USE CASE-1 How can I accept the above query parameters in the form a class from swagger, I know we can define…
Vaibhav Jain
  • 61
  • 1
  • 6
1
vote
1 answer

How to Add a field to struct golang using JEN package where fields depend on JSON

Looping through the Json and getting the "name" field with tags and then adding it into a block of struct. Required output after code generation var queryOutput [][]struct { product_name string `db:"product_name" json:"product_name"` …
omkar
  • 41
  • 4
1
vote
0 answers

Cannot read property 'name' of undefined when compiling a mutation using Codegen

I have a graphql/mutations/session.mutation.gql file: mutation CreateSession { createSession } // codegen.yml overwrite: true schema: "http://localhost:4000/graphql" documents: "**/*.{gql,graphql}" generates: src/generated/queries.tsx: …
Peter Boomsma
  • 8,851
  • 16
  • 93
  • 185