Add support for <simpleContent> #106
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Simple content is like... a simpler version of <complexContent> within a
<complexType>! This commit adds support for a <simpleContent> tag with
extensions/restrictions.
I'm looking at using wsdl2go for a quick integration with NetSuite, but hit an immediate hurdle of not having <simpleContent> be supported such that I could use the TokenPassportSignature element defined in https://webservices.netsuite.com/xsd/platform/v2018_1_0/core.xsd
I don't really know what I'm doing here, but this commit copies the approach to <complexContent> and strips down to the supported tags within <simpleContent>. The thing I'm least certain of is the
c > 2 && len(ct.Attributes) == 0
pre-condition change.With this change, and the above linked wsdl, you get output like:
(Where on
master
we hit thec > 2 [...]
precondition and generate an empty struct instead).