preview method

Preview fields auto-generated during router create andupdate operations. Calling this method does NOT create or update the router.

Throws a http.ClientException if there were problems communicating with the API service. Throws a ServiceException if the API method failed for any reason.

Implementation

@override
Future<RoutersPreviewResponse> preview(PreviewRouterRequest request) async {
  if (isClosed) throw StateError('Service is closed');

  if (_preview case final preview?) {
    return preview(request);
  }
  throw UnsupportedError('preview');
}