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

Added AgencyID, AgencyName, ListID. #29

Merged
merged 1 commit into from
Jul 29, 2020

Conversation

skinkie
Copy link
Contributor

@skinkie skinkie commented Jul 29, 2020

As discussed in #28.

I have not updated any of the other classes because it seems that the license is not added to the files by running the code. Neither did I update the other versions of the code lists. If you approve this addition I'll update the other versions as well.

@phax phax merged commit e1318a3 into phax:master Jul 29, 2020
@phax
Copy link
Owner

phax commented Jul 29, 2020

Thank you - I will change the names slightly so that they are all upper case and replicate it for the other UBL versions as well

@skinkie
Copy link
Contributor Author

skinkie commented Jul 31, 2020

@phax would you like it if we add something like this:

    public static QuantityType getQuantyType(EUnitOfMeasureCode21 eUnitOfMeasureCode21, BigDecimal value) {
        QuantityType quantityType = new QuantityType();
        quantityType.setUnitCodeListAgencyName(EUnitOfMeasureCode21.agencyName);
        quantityType.setUnitCodeListAgencyID(EUnitOfMeasureCode21.agencyID);
        quantityType.setUnitCodeListID(EUnitOfMeasureCode21.listID);
        quantityType.setUnitCode(eUnitOfMeasureCode21.getID());
        quantityType.setValue(value);
    }

phax added a commit that referenced this pull request Aug 28, 2020
@phax
Copy link
Owner

phax commented Aug 28, 2020

@skinkie In general that would be valuable but it guess that this is quite an effort to provide this for all 4 supported UBL versions in a "generic" way without bloating dependencies????

@skinkie
Copy link
Contributor Author

skinkie commented Aug 28, 2020

@skinkie In general that would be valuable but it guess that this is quite an effort to provide this for all 4 supported UBL versions in a "generic" way without bloating dependencies????

I wouldn't mind to generate the code at the same place that you use to generate the enumeration classes?

@phax
Copy link
Owner

phax commented Aug 28, 2020

Okay, and what value class (QuantityType) and enum (EUnitOfMeasureCode21) mappings do you have in mind?

@skinkie
Copy link
Contributor Author

skinkie commented Aug 28, 2020

Isn't the only place the unitofmeasurecode is used within the quantitytype?

@phax
Copy link
Owner

phax commented Aug 28, 2020

That's my problem - where would I look this up. Is there a technical resource where I can retrieve the information from?

@skinkie
Copy link
Contributor Author

skinkie commented Aug 28, 2020

@phax I guess the XSD? :-)

@phax
Copy link
Owner

phax commented Aug 28, 2020

Nope - in the XSD everything is a String. The codelists are provided as separate Genericode files and I am not aware of any linkage between them

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

Successfully merging this pull request may close these issues.

None yet

2 participants