+ private RpcResult<NetconfMessage> createSessionDownRpcResult()
+ {
+ return createErrorRpcResult( RpcError.ErrorType.TRANSPORT,
+ String.format( "The netconf session to %1$s is disconnected", id.getName() ) );
+ }
+
+ private RpcResult<NetconfMessage> createErrorRpcResult( RpcError.ErrorType errorType, String message )
+ {
+ return new FailedRpcResult<NetconfMessage>( RpcErrors.getRpcError( null,
+ NetconfDocumentedException.ErrorTag.operation_failed.getTagValue(),
+ null, RpcError.ErrorSeverity.ERROR, message, errorType, null ) );
+ }
+