public class NodeTypeDefDiff extends Object
NodeTypeDefDiff represents the result of the comparison of
two node type definitions.
The result of the comparison can be categorized as one of the following types:
NONE indicates that there is no modification at all.
A TRIVIAL modification has no impact on the consistency
of existing content. The following modifications are considered
TRIVIAL:
orderableChildNodes flag
primaryItemName value
mandatory property/child node
protected flag
onParentVersion value
mandatory flag to false
autoCreated flag
name to *
defaultPrimaryType
sameNameSiblings flag to true
requiredPrimaryTypes (e.g. by removing)
valueConstraints (e.g. by removing a constraint
or by making a specific constraint less restrictive)
defaultValues
requiredType to undefined
multiple flag to true
A MAJOR modification potentially affects the
consistency of existing content.
All modifications that are not TRIVIAL are considered
MAJOR.
getType()| Modifier and Type | Field and Description |
|---|---|
static int |
MAJOR
major modification: does affect consistency of existing content
|
static int |
NONE
no modification
|
static int |
TRIVIAL
trivial modification: does not affect consistency of existing content
|
| Modifier and Type | Method and Description |
|---|---|
int |
abstractFlagDiff() |
static NodeTypeDefDiff |
create(QNodeTypeDefinition oldDef,
QNodeTypeDefinition newDef) |
int |
getType()
Returns the type of modification as expressed by the following constants:
NONE: no modification at all
TRIVIAL: does not affect consistency of
existing content
MAJOR: does affect consistency of existing
content
|
boolean |
isMajor() |
boolean |
isModified() |
boolean |
isTrivial() |
int |
mixinFlagDiff() |
int |
supertypesDiff() |
String |
toString() |
public static final int NONE
public static final int TRIVIAL
public static final int MAJOR
public static NodeTypeDefDiff create(QNodeTypeDefinition oldDef, QNodeTypeDefinition newDef)
oldDef - old definitionnewDef - new definitionpublic boolean isModified()
true if modifiedpublic boolean isTrivial()
true if trivialpublic boolean isMajor()
true if majorpublic int getType()
NONE: no modification at all
TRIVIAL: does not affect consistency of
existing content
MAJOR: does affect consistency of existing
content
public int mixinFlagDiff()
true if mixin flag diffpublic int abstractFlagDiff()
true if abstract flag diffpublic int supertypesDiff()
true if supertypes diffCopyright © 2004–2020 The Apache Software Foundation. All rights reserved.