abstract class ModifiedDataTreeCandidateNode extends AbstractDataTreeCandidateNode {
private final Collection<DataTreeCandidateNode> children;
- private ModifiedDataTreeCandidateNode(final ModificationType type, final Collection<DataTreeCandidateNode> children) {
+ private ModifiedDataTreeCandidateNode(final ModificationType type,
+ final Collection<DataTreeCandidateNode> children) {
super(type);
this.children = Preconditions.checkNotNull(children);
}
- static DataTreeCandidateNode create(final Collection<DataTreeCandidateNode> children) {
- return new ModifiedDataTreeCandidateNode(ModificationType.SUBTREE_MODIFIED, children) {
+ static DataTreeCandidateNode create(final ModificationType type, final Collection<DataTreeCandidateNode> children) {
+ return new ModifiedDataTreeCandidateNode(type, children) {
@Override
public PathArgument getIdentifier() {
throw new UnsupportedOperationException("Root node does not have an identifier");
};
}
- static DataTreeCandidateNode create(final PathArgument identifier, final ModificationType type, final Collection<DataTreeCandidateNode> children) {
+ static DataTreeCandidateNode create(final PathArgument identifier, final ModificationType type,
+ final Collection<DataTreeCandidateNode> children) {
return new ModifiedDataTreeCandidateNode(type, children) {
@Override
- public final PathArgument getIdentifier() {
+ public PathArgument getIdentifier() {
return identifier;
}
};