import org.opendaylight.yangtools.rfc6643.model.api.SubIdStatement;
import org.opendaylight.yangtools.yang.common.QName;
import org.opendaylight.yangtools.yang.common.Uint32;
-import org.opendaylight.yangtools.yang.model.api.SchemaNodeDefaults;
-import org.opendaylight.yangtools.yang.model.api.SchemaPath;
import org.opendaylight.yangtools.yang.model.api.meta.EffectiveStatement;
import org.opendaylight.yangtools.yang.parser.rfc7950.stmt.UnknownEffectiveStatementBase;
import org.opendaylight.yangtools.yang.parser.spi.meta.EffectiveStmtCtx.Current;
-import org.opendaylight.yangtools.yang.parser.spi.meta.SchemaPathSupport;
final class SubIdEffectiveStatementImpl extends UnknownEffectiveStatementBase<Uint32, SubIdStatement>
implements SubIdEffectiveStatement, SubIdSchemaNode {
-
- private final SchemaPath path;
-
SubIdEffectiveStatementImpl(final Current<Uint32, SubIdStatement> stmt,
final ImmutableList<? extends EffectiveStatement<?, ?>> substatements) {
super(stmt, substatements);
- path = SchemaPathSupport.toOptionalPath(stmt.getEffectiveParent().getSchemaPath().createChild(getNodeType()));
}
@Override
return getNodeType();
}
- @Override
- @Deprecated
- public SchemaPath getPath() {
- return SchemaNodeDefaults.throwUnsupportedIfNull(this, path);
- }
-
@Override
public SubIdEffectiveStatement asEffectiveStatement() {
return this;
@Override
public int hashCode() {
- return Objects.hash(path, getNodeType(), getNodeParameter());
+ return Objects.hash(getNodeType(), getNodeParameter());
}
@Override
}
final SubIdEffectiveStatementImpl other = (SubIdEffectiveStatementImpl) obj;
return Objects.equals(getNodeType(), other.getNodeType())
- && Objects.equals(getNodeParameter(), other.getNodeParameter()) && Objects.equals(path, other.path);
+ && Objects.equals(getNodeParameter(), other.getNodeParameter());
}
}