abstract class AbstractLeafrefSpecificationSupport
extends BaseStatementSupport<String, LeafrefSpecification, EffectiveStatement<String, LeafrefSpecification>> {
AbstractLeafrefSpecificationSupport() {
- super(YangStmtMapping.TYPE);
+ super(YangStmtMapping.TYPE, CopyPolicy.DECLARED_COPY);
}
@Override
@Override
protected final LeafrefSpecification createDeclared(final StmtContext<String, LeafrefSpecification, ?> ctx,
final ImmutableList<? extends DeclaredStatement<?>> substatements) {
- return new LeafrefSpecificationImpl(ctx.coerceRawStatementArgument(), substatements);
+ return new LeafrefSpecificationImpl(ctx.getRawArgument(), substatements);
}
@Override
throw noPath(stmt);
}
- final LeafrefTypeBuilder builder = BaseTypes.leafrefTypeBuilder(stmt.getSchemaPath());
+ final LeafrefTypeBuilder builder = BaseTypes.leafrefTypeBuilder(stmt.wrapSchemaPath());
for (final EffectiveStatement<?, ?> subStmt : substatements) {
if (subStmt instanceof PathEffectiveStatement) {
* When the type is "union", the "type" statement (Section 7.4) MUST be
* present.
*/
- return new SourceException("A path statement has to be present", stmt.sourceReference());
+ return new SourceException("A path statement has to be present", stmt);
}
}
\ No newline at end of file