X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=yang%2Fyang-parser-impl%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fyangtools%2Fyang%2Fparser%2Fbuilder%2Fapi%2FAugmentationSchemaBuilder.java;h=696e586122abfb4ca57959388a37aa7db9906718;hb=7729326086d90184e7f167e628fe9c8ce9e5a437;hp=6b1e49e1ed1d954a2d53b13be978c454a416b2b2;hpb=45cc8ec7bc55e59639ae3df1b8f1c35fe7026386;p=yangtools.git diff --git a/yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/builder/api/AugmentationSchemaBuilder.java b/yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/builder/api/AugmentationSchemaBuilder.java index 6b1e49e1ed..696e586122 100644 --- a/yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/builder/api/AugmentationSchemaBuilder.java +++ b/yang/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/builder/api/AugmentationSchemaBuilder.java @@ -9,31 +9,41 @@ package org.opendaylight.yangtools.yang.parser.builder.api; import org.opendaylight.yangtools.yang.model.api.AugmentationSchema; import org.opendaylight.yangtools.yang.model.api.SchemaPath; -import org.opendaylight.yangtools.yang.model.api.Status; /** - * Interface for builders of 'augment' statement. + * Builder for {@link AugmentationSchema}, which represents 'augment' statement. */ -public interface AugmentationSchemaBuilder extends DataNodeContainerBuilder { +public interface AugmentationSchemaBuilder extends DataNodeContainerBuilder,DocumentedNodeBuilder { + /** + * Returns when condition + * + * If when condition is present node defined by the parent data definition + * statement is only valid when the returned XPath + * expression conceptually evaluates to "true" + * for a particular instance, then the node defined by the parent data + * definition statement is valid; otherwise, it is not. + * + * + * @return + */ String getWhenCondition(); + /** + * Adds string representation of when condition. + * + * If when condition is present node defined by the parent data definition + * statement is only valid when the returned XPath + * expression conceptually evaluates to "true" + * for a particular instance, then the node defined by the parent data + * definition statement is valid; otherwise, it is not. + * + * @param whenCondition + */ void addWhenCondition(String whenCondition); - String getDescription(); - - void setDescription(String description); - - String getReference(); - - void setReference(String reference); - - Status getStatus(); - - void setStatus(Status status); - /** - * Get path to target node as single string. + * Returns target path representation as was present in schema source. * * @return path to target node as String */ @@ -65,6 +75,7 @@ public interface AugmentationSchemaBuilder extends DataNodeContainerBuilder { */ void setTargetNodeSchemaPath(SchemaPath path); + @Override AugmentationSchema build(); /** @@ -82,6 +93,13 @@ public interface AugmentationSchemaBuilder extends DataNodeContainerBuilder { */ void setResolved(boolean resolved); + /** + * + * Returns position of defining augment statement + * as was present in schema source. + * + * @return Position of definiing augment statement in source code. + */ int getOrder(); }