Comments (5)
Why shouldn't inheritance:extends
override xs:extension
if you
explicitly specify it?
On Mon, Dec 14, 2015 at 3:54 PM, krokodylowy [email protected]
wrote:
If binding is extended with inheritance:extends=someClass then someClass
overrides
mainClass defined in element with xs:extension base=mainClassIf binding contains xjc:superClass name=someClass then behavior is correct
and
mainClass from xs:extension base=mainClass is not overriden by someClass
(someClass is added only to class without extends)—
Reply to this email directly or view it on GitHub
#43.
from jaxb2-basics.
Because xjc:superClass doesn't do it. I tried use inheritance:extends as replacement but it's dangerous.
Super type declared in xs:extension is ignored
from jaxb2-basics.
inhertitance:extends
is not meant as a replacement for xjc:superClass
. Why should it be if you have xjc:superClass
?
It is predictable and deterministic in what it does, so not exactly fits in my understanding of "dangerous".
from jaxb2-basics.
Why should it be if you have xjc:superClass
No. If I remove xjc:superClass and include inhertitance:extends results can be different
in java class code at line with 'class x extends y'
BTW.
I found it as workaround for #42. Code with xjc:superClass doesn't generate correct clone,hash and equals but inhertitance:extends do it correctly.
from jaxb2-basics.
I'm inclined to close it as it is works as designed. inheritance:extends
will make the generated class extend the given class, no matter what.
If you really need the functionality "don't force extends", I'd see it as another issue. But I'd really like to know why it is needed. The only thing I can imaging is if you're using a mulinode XPath select in the binding to apply the customization to many nodes at once.
from jaxb2-basics.
Related Issues (20)
- Update build to use maven release plugin
- Reverting jakarta initial changes HOT 1
- Update to latests jaxb v2.x
- Update to JUnit 4.13.2
- Upgrade to commons-io 2.11.0
- Update to JDK 1.8 minimum for source and target
- Add support for building with JDK 9+
- Update maven scm for release automation
- Bump version to 0.13.0-SNAPSHOT
- Fix maven-deploy-plugin / oss-staging-plugin fighting each other
- Update version to 2.3.6-SNAPSHOT
- Migrate to jakarta.oss.sonatype.org HOT 1
- Take over the remaining jaxb2_commons plugins HOT 11
- Bump commons-beanutils HOT 10
- Jakarta classes support for jaxb2-basics HOT 20
- Simplifying element (rather than type) results in 'Unable to honor this as-element-property customization. It is attached to a wrong place, or its inconsistent with other bindings.'. HOT 1
- Possibilty to find a fix for fixedValues in ComplexType restriction
- Prepare migration to jakarta HOT 1
- Is the latest release published on Maven Repository? HOT 6
- Other xjc plugins repository - maybe useful source code
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jaxb2-basics.