* @author Robert Varga
*/
@Beta
-// FIXME: 5.0.0: consider moving this class to api to keep related stuff together
+// FIXME: 6.0.0: consider moving this class to api to keep related stuff together
public final class NormalizedMetadataWriter implements Closeable, Flushable {
private final NormalizedNodeStreamWriter writer;
private final boolean orderKeyLeaves;
* operates w.r.t. mount points. Further evolution is expected.
*/
/*
- * FIXME: 5.0.0: consider yang-data-api integration
+ * FIXME: 6.0.0: consider yang-data-api integration
*
* The above note does not give the subject enough attention. RFC8528 redefines the YANG data metamodel is significant
* ways in that it ties it with RFC8525/RFC7895. The content of 'schema-mounts' is critical to interpreting
* seamless.
*/
/*
- * FIXME: 5.0.0: The above is not quite right. DataTree instances should be able to handle mount points and correctly
+ * FIXME: 6.0.0: The above is not quite right. DataTree instances should be able to handle mount points and correctly
* handle them, provided they get enough support from MountPointContext.
*/
@Beta
* Abstract base class for dynamic resolvers.
*/
@Beta
-// FIXME: 5.0.0: consider integrating into AbstractMountPointContextFactory
+// FIXME: 6.0.0: consider integrating into AbstractMountPointContextFactory
public abstract class AbstractDynamicMountPointContextFactory extends AbstractIdentifiable<MountPointIdentifier>
implements MountPointContextFactory {
private static final Logger LOG = LoggerFactory.getLogger(AbstractDynamicMountPointContextFactory.class);
return config;
}
- // FIXME: 5.0.0: make this return a set of XPath expressions
+ // FIXME: 6.0.0: make this return a set of XPath expressions
public ImmutableSet<String> getParentReferences() {
return parentReferences;
}
* @param <V> Value of node
*/
/*
- * FIXME: 5.0.0: NormalizedNode represents the perfectly-compliant view of the data, as evaluated by an implementation,
+ * FIXME: 6.0.0: NormalizedNode represents the perfectly-compliant view of the data, as evaluated by an implementation,
* which is currently singular, with respect of its interpretation of a SchemaContext. This includes
* leaf values, which are required to hold normalized representation for a particular implementation,
* which may be affected by its understanding of any YANG extensions present -- such as optional type
* concept which contains an unverified, potentially non-conformant data tree, which the consumer needs
* to check/fixup if it wishes to use it as a NormalizedNode. Such a concept should be called
* "UnverifiedData".
- */
-/*
- * FIXME: 5.0.0: Once we have UnverifiedData, we should really rename this to "NormalizedData" or similar to unload
+ *
+ * FIXME: 6.0.0: Once we have UnverifiedData, we should really rename this to "NormalizedData" or similar to unload
* some "Node" ambiguity. "Node" should be a generic term reserved for a particular domain -- hence 'node'
* can be used to refer to either a 'schema node' in context of yang.model.api, or to
* a 'normalized data node' in context of yang.data.api.
*
- * FIXME: 5.0.0: Well, not quite. The structure of unverified data is really codec specific -- and JSON and XML
+ * FIXME: 6.0.0: Well, not quite. The structure of unverified data is really codec specific -- and JSON and XML
* do not agree on details. Furthermore things get way more complicated when we have a cross-schema
* boundary -- like RFC8528. Hence we cannot really have a reasonably-structured concept of unverified
* data. Nevertheless, this interface should be named 'NormalizedData'.
* implementation does not allow resetting the value.
* @throws IOException if an underlying IO error occurs
*/
- // FIXME: 5.0.0: this probably should integrated with scalarValue()
+ // FIXME: 6.0.0: this probably should integrated with scalarValue()
void domSourceValue(DOMSource value) throws IOException;
/**
* the modification from which this candidate was created. The node itself exposes the before- and after-image
* of the tree restricted to the modified nodes.
*/
-// FIXME: 5.0.0: Use @NonNullByDefault
public interface DataTreeCandidateNode {
/**
* Get the node identifier.
* <a href="https://tools.ietf.org/html/rfc6020#section-7.19.1">RFC7950</a> data combinations based on {@code config}
* statement.
*/
-// FIXME: 5.0.0: Consider defining a 'config false'-only type
-// FIXME: 5.0.0: Consider renaming this enum
+// FIXME: 6.0.0: Consider defining a 'config false'-only type
+// FIXME: 6.0.0: Consider renaming this enum
@Beta
public enum TreeType {
/**
* A mutable tree node. This is a transient view materialized from a pre-existing node. Modifications are isolated. Once
* this object is {@link #seal()}ed, any interactions with it will result in undefined behavior.
*/
-// FIXME: 5.0.0: Use @NonNullByDefault
public interface MutableTreeNode extends StoreTreeNode<TreeNode> {
/**
* Set the data component of the node.
// Returns a one-off factory for the purposes of normalizing an anydata tree.
//
- // FIXME: 5.0.0: this is really ugly, as we should be able to tell if the new context is the same as ours and
+ // FIXME: 6.0.0: this is really ugly, as we should be able to tell if the new context is the same as ours and
// whether our cache is thread-safe -- in which case we should just return this.
// The supplier/cache/factory layout needs to be reworked so that this call ends up being equivalent
// to JSONCodecFactorySupplier.getShared() in case this factory is not thread safe.
import com.google.common.annotations.Beta;
import org.opendaylight.yangtools.concepts.AbstractIllegalArgumentCodec;
-// FIXME: 5.0.0: yang-data-api is tied to yang-model-api, hence it should be opinionated to export exceptions
+// FIXME: 6.0.0: yang-data-api is tied to yang-model-api, hence it should be opinionated to export exceptions
// encapsulating YANG-based error information.
@Beta
public abstract class AbstractDataStringCodec<T> extends AbstractIllegalArgumentCodec<String, T>
import org.eclipse.jdt.annotation.NonNull;
import org.opendaylight.yangtools.concepts.IllegalArgumentCodec;
-// FIXME: 5.0.0: yang-data-api is tied to yang-model-api, hence it should be opinionated to export exceptions
+// FIXME: 6.0.0: yang-data-api is tied to yang-model-api, hence it should be opinionated to export exceptions
// encapsulating YANG-based error information.
public interface DataStringCodec<T> extends IllegalArgumentCodec<String, T> {
import org.opendaylight.yangtools.yang.model.api.SchemaPath;
import org.opendaylight.yangtools.yang.model.util.AbstractSchemaContextProvider;
-// FIXME: 5.0.0 hide this class
public final class LeafRefContext extends AbstractSchemaContextProvider {
private final QName currentNodeQName;
*
* @author Robert Varga
*/
-// FIXME: 5.0.0: @NonNullByDefault
+// FIXME: 6.0.0: @NonNullByDefault
public final class DataSchemaContextTree {
private static final LoadingCache<SchemaContext, DataSchemaContextTree> TREES = CacheBuilder.newBuilder()
.weakKeys().weakValues().build(new CacheLoader<SchemaContext, DataSchemaContextTree>() {
* @author Robert Varga
*/
@Beta
-// FIXME: 5.0.0: evaluate if we still need to extend SchemaContext here
+// FIXME: 6.0.0: evaluate if we still need to extend SchemaContext here
public interface EffectiveModelContext extends SchemaContext {
Map<QNameModule, ModuleEffectiveStatement> getModuleStatements();
package org.opendaylight.yangtools.yang.model.api;
import java.util.Optional;
+import org.eclipse.jdt.annotation.NonNull;
import org.opendaylight.yangtools.concepts.SemVer;
import org.opendaylight.yangtools.yang.common.Revision;
/**
- * Interface describing YANG 'import' statement.
- *
- * <p>
- * The import statement makes definitions from one module available inside another module or submodule.
+ * Interface describing YANG 'import' statement. The import statement makes definitions from one module available inside
+ * another module or submodule.
*/
-// FIXME: 5.0.0 this class is a leak of the declared world into the effective one. In effective world, all nodes form
-// a tree, which consists of multiple (mostly) QName-navigated namespaces. As such module imports contribute
-// only a prefix/QNameModule mapping to the effective world and hence should be mapped that way:
-// - Module exposes String->QNameModule mapping
+// FIXME: 6.0.0: this class is a leak of the declared world into the effective one. In effective world, all nodes form
+// a tree, which consists of multiple (mostly) QName-navigated namespaces. As such module imports
+// contribute only a prefix/QNameModule mapping to the effective world and hence should be mapped that
+// way:
+// - Module exposes String->QNameModule mapping
public interface ModuleImport extends DocumentedNode {
/**
* Returns the name of the module to import.
*
* @return Name of the module to import
*/
- String getModuleName();
+ @NonNull String getModuleName();
/**
* Returns the module revision to import. May be null.
*
* @return Prefix used to point to imported module
*/
- String getPrefix();
+ @NonNull String getPrefix();
}
import java.util.Optional;
import org.opendaylight.yangtools.yang.common.Revision;
-// FIXME: 5.0.0: this really is QNameModuleAware (or some such)
+// FIXME: 6.0.0: this really is QNameModuleAware (or some such)
public interface NamespaceRevisionAware {
URI getNamespace();
/**
* Contains methods for getting data (concrete XPath) and metadata (is XPath absolute) from XPath instance.
*/
-// FIXME: 5.0.0: find a better name for this interface
+// FIXME: 6.0.0: find a better name for this interface
public interface RevisionAwareXPath {
/**
* Returns <code>true</code> if the XPapth starts in root of Yang model, otherwise returns <code>false</code>.
@NonNull String getOriginalString();
@Beta
- // FIXME: 5.0.0: integrate this interface into RevisionAwareXPath
+ // FIXME: 6.0.0: integrate this interface into RevisionAwareXPath
interface WithExpression extends RevisionAwareXPath {
/**
* Return the {@link YangXPathExpression} of this XPath. The expression is required to be at least
* Effective view of a {@link ModuleStatement}.
*/
@Beta
-// FIXME: 5.0.0: we should reshuffle the String here, as module name is in reality a YANG identifier, e.g. not just
+// FIXME: 6.0.0: we should reshuffle the String here, as module name is in reality a YANG identifier, e.g. not just
// an ordinary String. We really want this to be a QName, so that we do not need the localQNameModule
// bit, but that may be problematic with ModuleStatement, which is getting created before we even know
// the namespace :( A type capture of the string may just be sufficient.
* {@link SourceIdentifier}s are required and dynamic recursive resolution.
*/
@Beta
-//FIXME: 5.0.0: evaluate if we still need to extend SchemaContext here
+// FIXME: 6.0.0: evaluate if we still need to extend SchemaContext here
public interface EffectiveModelContextFactory extends SchemaContextFactory {
/**
* Create a new schema context containing specified sources, pulling in any dependencies they may have.
.addValidationBundle(ValidationBundleType.SUPPORTED_AUGMENT_TARGETS,
YangValidationBundles.SUPPORTED_AUGMENT_TARGETS)
- // FIXME: 5.0.0: we do not seem to need this validation bundle
+ // FIXME: 6.0.0: we do not seem to need this validation bundle
.addValidationBundle(ValidationBundleType.SUPPORTED_CASE_SHORTHANDS,
YangValidationBundles.SUPPORTED_CASE_SHORTHANDS)
*
* @deprecated This is an implementation leak from statement support and will be removed in next major version.
*/
- // FIXME: 5.0.0: move this to AbstractDeviateStatementSupport. This is not resolved from validation bundles at all,
+ // FIXME: 6.0.0: move this to AbstractDeviateStatementSupport. This is not resolved from validation bundles at all,
// hence it makes sense to co-locate this with its user.
@Deprecated
public static final Table<YangVersion, StatementDefinition, Set<StatementDefinition>> SUPPORTED_DEVIATION_TARGETS =
YangStmtMapping.CONTAINER, YangStmtMapping.LIST, YangStmtMapping.CASE, YangStmtMapping.INPUT,
YangStmtMapping.OUTPUT, YangStmtMapping.NOTIFICATION, YangStmtMapping.CHOICE, YangStmtMapping.RPC);
- // FIXME: 5.0.0: consider hiding this list, as choice nodes are handling creation of implied shorthands themselves.
+ // FIXME: 6.0.0: consider hiding this list, as choice nodes are handling creation of implied shorthands themselves.
// This has implications on other members of this class, as they really seem like something which
// should live in corresponding StatementSupport classes.
public static final Set<StatementDefinition> SUPPORTED_CASE_SHORTHANDS = ImmutableSet.of(
* The reactor would first inline 'uses baz' as that definition is the first one completely resolved and then
* inline 'uses bar'. Here we are iterating in declaration order re-inline the statements.
*
- * FIXME: 5.0.0: this really should be handled by UsesStatementSupport such that 'uses baz' would have a
+ * FIXME: 6.0.0: this really should be handled by UsesStatementSupport such that 'uses baz' would have a
* prerequisite of a resolved 'uses bar'.
*/
final List<StmtContext<?, ?, ?>> substatementsInit = new ArrayList<>();
import org.opendaylight.yangtools.yang.parser.rfc7950.stmt.AbstractEffectiveDocumentedNode;
import org.opendaylight.yangtools.yang.parser.spi.meta.StmtContext;
-// FIXME: 5.0.0: hide this class
+// FIXME: 6.0.0: hide this class
public final class EnumEffectiveStatementImpl extends AbstractEffectiveDocumentedNode<String, EnumStatement>
implements EnumEffectiveStatement {
private final String name;
import org.opendaylight.yangtools.yang.parser.rfc7950.stmt.AbstractEffectiveDocumentedNode;
import org.opendaylight.yangtools.yang.parser.spi.meta.StmtContext;
-// FIXME: 5.0.0: hide this class
+// FIXME: 6.0.0: hide this class
public final class RefineEffectiveStatementImpl
extends AbstractEffectiveDocumentedNode<Descendant, RefineStatement>
implements RefineEffectiveStatement, SchemaNode {
@Override
public final <K, V, N extends IdentifierNamespace<K, V>> Optional<? extends V> get(final Class<N> namespace,
final K identifier) {
- // FIXME: 5.0.0: implement this
+ // FIXME: 6.0.0: implement this
return Optional.empty();
}
@Override
public final <K, V, N extends IdentifierNamespace<K, V>> Map<K, V> getAll(final Class<N> namespace) {
- // FIXME: 5.0.0: implement this
+ // FIXME: 6.0.0: implement this
return ImmutableMap.of();
}
/**
* Storage of the root statement of a particular source and any sources it is importing.
*/
- // FIXME: 5.0.0: this is a misnomer and should be renamed
+ // FIXME: 6.0.0: this is a misnomer and should be renamed
SOURCE_LOCAL_SPECIAL,
/**
* Storage of a single statement.
* build full declared statement model of source.</li>
* </ol>
*/
-// FIXME: 5.0.0: this is a push parser, essentially traversing the same tree multiple times. Perhaps we should create
+// FIXME: 6.0.0: this is a push parser, essentially traversing the same tree multiple times. Perhaps we should create
// a visitor/filter or perform some explicit argument binding?
public interface StatementStreamSource extends Identifiable<SourceIdentifier> {
/**
* Whether a <a href="https://tools.ietf.org/html/rfc6020#section-7.9.2">case shorthand</a> can be created for a
* node.
*/
- // FIXME: 5.0.0: consider removing this constant, this functionality is part of statement support.
+ // FIXME: 6.0.0: consider removing this constant, this functionality is part of statement support.
SUPPORTED_CASE_SHORTHANDS,
/**