return Futures.immediateFailedFuture(
new MissingSchemaSourceException("No source registered", sourceIdentifier));
}
- return Futures.immediateFuture(YangTextSchemaSource.delegateForByteSource(sourceIdentifier,
- info.getYangTextByteSource()));
+ return Futures.immediateFuture(YangTextSchemaSource.delegateForCharSource(sourceIdentifier,
+ info.getYangTextCharSource()));
}
@Override
}
static @NonNull YangTextSchemaSource toYangTextSource(final YangModuleInfo moduleInfo) {
- return YangTextSchemaSource.delegateForByteSource(sourceIdentifierFrom(moduleInfo),
- moduleInfo.getYangTextByteSource());
+ return YangTextSchemaSource.delegateForCharSource(sourceIdentifierFrom(moduleInfo),
+ moduleInfo.getYangTextCharSource());
}
private static @NonNull YangTextSchemaSource toYangTextSource(final SourceIdentifier identifier,
final YangModuleInfo moduleInfo) {
- return YangTextSchemaSource.delegateForByteSource(identifier, moduleInfo.getYangTextByteSource());
+ return YangTextSchemaSource.delegateForCharSource(identifier, moduleInfo.getYangTextCharSource());
}
private static SourceIdentifier sourceIdentifierFrom(final YangModuleInfo moduleInfo) {
final class Rpcs {
static final EffectiveModelContext CONTEXT = YangParserTestUtils.parseYangSources(YangParserConfiguration.DEFAULT,
null,
- YangTextSchemaSource.delegateForByteSource("yang-ext.yang",
- $YangModuleInfoImpl.getInstance().getYangTextByteSource()),
+ YangTextSchemaSource.delegateForCharSource("yang-ext.yang",
+ $YangModuleInfoImpl.getInstance().getYangTextCharSource()),
YangTextSchemaSource.forResource(Rpcs.class, "/rpcs.yang"));
static final QName FOO = QName.create("rpcs", "foo");
@BeforeClass
public static void beforeClass() {
final var ctx = YangParserTestUtils.parseYangSources(YangParserConfiguration.DEFAULT, null,
- YangTextSchemaSource.delegateForByteSource("yang-ext.yang",
- $YangModuleInfoImpl.getInstance().getYangTextByteSource()),
+ YangTextSchemaSource.delegateForCharSource("yang-ext.yang",
+ $YangModuleInfoImpl.getInstance().getYangTextCharSource()),
YangTextSchemaSource.forResource(ContentRoutedRpcContext.class, "/rpc-routing-strategy.yang"));
RPCS = ctx.findModuleStatements("foo").iterator().next()