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

Values of properties with multiple ranges are not properly casted #3

Open
schwichti opened this issue May 14, 2018 · 0 comments
Open

Comments

@schwichti
Copy link
Owner

  • An input parameter "latitude" is declared as type integer in Open API specification
  • It is mapped to <GeoCoordinates, latitude, Number> in the alignment
  • Note that http://schema.org/latitude has range {Number, Text}
  • Code generator generates this line:
public Airport ReferencesAirportsNearestByLatitudeAndLongitudeGet(GeoCoordinates latitude,...){
 int latitude_ = latitude.getLatitude();
}

However, this gives a compile error, because the casting argument is missing. The correct call would look like this:

int latitude_ = latitude.getLatitude(Integer.class);
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

1 participant