将 WPF NHibernate 客户端服务器桌面应用程序移至可从多个位置访问的最佳方法

发布于 2024-10-04 03:22:55 字数 476 浏览 4 评论 0原文

就知识而言,我从头开始使用 WPF 和 NHibernate 编写了一个桌面应用程序。这帮助我加快了 NHibernate 和 WPF 的使用速度。

然而,需要使应用程序能够从多个位置访问 - 这些包括具有非常简单的 Web 浏览器(无 JavaScript 功能)的手持设备、Web 服务、互联网、桌面应用程序和潜在的其他用户界面。

我相信这需要将应用程序从当前部署在客户端上的 NHibernate.dll 迁移到基于 Web 的应用程序。技术堆栈的纯粹选择是压倒性的,我希望我能找到正确的方向。

本质上,我希望能够从桌面客户端的服务器端、Web 服务、手持设备访问数据。

在服务器端,我想我会有一个 Web 服务器(IIS?)、NHibernate 和数据库以及客户端和服务器之间的某种通信方式。

在这种情况下最好的选择是什么?是休息吗?肥皂?世界CF?有什么我不知道/没有提到的吗?

任何来自实施过类似事情的人的帮助和建议将非常感激。

Starting from scratch in terms of knowledge I have written a desktop application using WPF and NHibernate. This has helped me get up to speed with both NHibernate and WPF.

However, there is a requirement to make the application so that it can be accessed from mutliple places - these include handheld devices which have very simple web browser (no javascript capability), web services, Internet, the desktop application and potentially other user interfaces.

I believe this requires moving the application from its current NHibernate.dll deployed on the client to a web based application. The sheer choice of technology stacks is overwhelming and I am hoping I can get pointed in the right direction.

In essence, I want to be able to access the data from the server side in the desktop client, from the web service, from the handheld devices.

On the server side I guess I would have a web server(IIS?), NHibernate and a database and some way of communicating between the clients and the server.

What would be the best choice in this circumstance? Is it REST? SOAP? WCF? Something I don't know about / haven't mentioned?

Any assistance and advice from people who have implemented similar things would be very much appreciated.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

在巴黎塔顶看东京樱花 2024-10-11 03:22:55

既然您已经在桌面上完成了大部分工作,那么将实际的数据访问部分转移到 Web 服务上并不困难。

如果我是您,我会进行该转换并使 SOAP/WCF 服务具有与数据层相同的签名(或至少尽可能接近)。这将使您已经编写的桌面应用程序的转换更加容易。您必须添加用于同步的代码,或者仅添加用于服务无法访问时的安全代码。

对于通过像浏览器一样的瘦 Web 客户端进行移动访问,您正在查看一个接触数据库(可能通过相同的数据访问 Web 服务)并生成 html 的网站/应用程序...

我无法在休息/之间提供建议肥皂/WCF,因为我之前对所有这些都有一些经验,但我可以告诉你,我已经创建了一个类似的设置,其中包含一个 SOAP WebService,为 WM6+ 提供 Web 应用程序和 .NET Compact Framework 应用程序,并且效果很好。

Well since you have already made most of the work on the desktop, moving the actual data access part on a webservice is not going to be hard.

If i were you i would make that transition and make a SOAP/WCF service have the same signatures (or at least as close as possible) as the data layer. This will make the transition for your already written desktop application easier. You will have to add code for synchronizing or just safety code for when the service is inaccesible.

For mobile access via a thin web client as the browser is, you are looking at a web site/application that touches the DB (possibly via the same data-access webservice) and generates html...

I can't advise between rest/soap/wcf as i have minor prior experience with all, but i can tell you that i have created a similar setup with a SOAP WebService feeding a Web Application and .NET Compact Framework Application for WM6+ and it works well.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文