天天看点

The Practice of .NET Cross-Platforms

The Practice of .NET Cross-Platforms

The detials from my practice on .NET Cross-platforms

0x01 Preface

  This post is mainly to share the technologies on my practice about the .NET Cross-Platforms.

If you had watched my first top post,you will know most of technologies uesd in my practice.Now,

I will Introduce the detials about this. Ready to go? Let's start!

0x02 What I am using 

1.  Xamarin

   Using the Xamarin to build the mobile Apps,such as the Android app and the IOS app.but in

my practice,I only completed the Android app,the IOS app didn't complete yet,Ohm..because I do

not hava a Mac,I can't compiler the application.

2. Universal Windows Platform(UWP)

  Using the UWP to build the App of Windows Phone mobile or Windows . Due to my busy job,I can't

complete it as well . I am learning the Encrypt and Decrypt Algorithms on the UWP , there are some

differents between UWP and other situation,such as the namespace,the dealing method.

3. NancyFx

  Using the NancyFx to build the manage website and the data service website.The manage website

is hosting with aspnet and the data service website is hosting with owin.

4. MongoDB(Migrated from MS SQL Server)

  At first,I use the MS SQL Server as my database , but I think it is not suitable for  a little application .

So I migrated the database from MS SQL Server to MongoDB.And I use RobThree's MongoRepository to 

Operate the MongoDB. It's very convenient to use MongoRepository like the Entity Framework , but there

are some differents between them.

0x03 How do I do

Let's look at the below picture first.

The Practice of .NET Cross-Platforms

There are two websites : one is the data service,providing the services for the mobile,

the other one is the manage website,managing the data of this system.

The more detials are as follow:

I use two Virtual Machines to host the Data Service and the Manage website.The Operation

System of both two Virtual machines is CentOS. 

For the Data Service,I depoly it with the TinyFox . The Data Service is based on the NancyFx

and OWIN,why I choose this combination? RESTful , RESTful , RESTful .This combination do

well in it . You can try this combination in your project. 

The Practice of .NET Cross-Platforms

For the Manage Website,I depoly it with the Jexus . The Manage Website is based on the NancyFx

Hosting with asp.net.So, there is no doubt that I will choose the Jexus for the Server.

The Practice of .NET Cross-Platforms

If you do not hava any ideas of Jexus and the TinyFox , you can find them in  http://linuxdot.net/ 

And what about the database?

I use my own compute to host the MongoDB.I build a service for MongoDB so that makes it easy to use.

The Practice of .NET Cross-Platforms

Completed the above step, all of the things are done.At this time, the apps can run successfully.

0x04  What I am thinking about the next

  Using the Xamarin to build the Navite Apps is a very good things,we can do everything like

the Navite Android and the IOS.Xamarin.Android and the Xamarin.IOS can do those work for us .

And I think the Xamarin.Forms may more suitable for what I do . And there are some problems

when I use the Xamarin.Forms .  For everything ,  the best way may not exist , but the suitable way do exist .

  Using the NancyFx to build the data service and the manage website will not change.I konw

the asp.net core rtm will Release soon,but I still do not want to use it now. The NancyFx team is also working hard .

  The Cross-Platforms is very nice.        

  This is  the first time for me to use the english to write a post, so many oral english here. Please forgive me and

my mistakes on this post.

  And I am ready to find a new job after finishing all of my tasks . Maybe one month or a little more . If your company need

a developer not on time , you can Contact with me.

  At last,the source code 

  https://github.com/hwqdt/Catcher.Finance

The Practice of .NET Cross-Platforms

如果您认为这篇文章还不错或者有所收获,可以点击右下角的【推荐】按钮,因为你的支持是我继续写作,分享的最大动力!

作者:Catcher Wong ( 黄文清 )

来源:http://catcher1994.cnblogs.com/

声明:

本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。如果您发现博客中出现了错误,或者有更好的建议、想法,请及时与我联系!!如果想找我私下交流,可以私信或者加我微信。

继续阅读