Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I like GWT but I prefer to use ASP.NET MVC for my projects, however, these two are not integrated and require me to write my code in two different platforms and two languages. Does Microsoft have any solutions comparable to GWT for compiling C# into JavaScript? I know there is Script# which is not supported by MS and the Volta project which was killed after its preview, but I was wondering if there is any good solutions available now or at least some good open source project that can integrate ASP.NET with GWT. Thanks.
Well, I can tell you what my preferred stack looks like these days. To me it is a nice balance of established tech with flexibility, though keep in mind I use this mostly to build single-page ajax "apps", not for the traditional collection of pages.
Sharp UI (full disclosure: this is one of my open source projects)
Script#
jQuery
I use a tool I wrote internally for generating "packet" classes shared by WCF and Script#.
WCF (in JSON)
ASP.NET (either Webforms or MVC)
I get compile-time type checking from Script#, UI control encapsulation from Sharp UI, fairly easy to maintain JSON service endpoints through WCF and my code generation tool, and ASP.NET for misc or traditional web pages. I'm firing on all 8 cylinders with this setup.
Bridge.NET is in this space. It describes itself as:
Open Source C# to JavaScript Compiler and Frameworks.
Run Your App On Any Device Using JavaScript.
The Microsoft driven solution is TypeScript which is a separate language made with input from the lead architect of C#, Anders Hejlsberg. It is also open source.
Good suggestion, but as AFAIK there is absolutely nothing like GWT in the .Net world.
I'm a Java and .Net programmer. I've battled infrequently with javascript for about 3 years, and never become comfortable with it. Since adopting GWT I'm producing Javascript=based web pages but coding in Java - I absolutely adore it ;-)
There's no great reason why there can't be a .Net equivalant of GWT. GWT doesn't do a 'literal copy' of Java to produce the Javascript - so it doesn't rely on the two languages having a 'similar' grammer. Any language could be converted. Mind you, it would take a lot of effort to duplicate the analysis and optimisation performed by the GWT compiler in producing it's js files.
A more effective route may be to find a C# to Java converter, and then pass the output to GWT.
SharpKit for C# .NET is like GWT but actually does much more. They even have a CLR written entirely in Javascript that provides Reflection, Generics, etc. on the client.
http://sharpkit.net
Related
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
Improve this question
My background is mostly in desktop applications on the Microsoft platform. I've been working a lot with ASP.Net MVC lately and completely skipped over learning webforms. I find I'm having the most trouble (not being a web guy) with writing my views in MVC. How proficient should I be with HTML and javascript to write good views in MVC? Also, is the standard Webforms view engine what I should go with, or would I have an easier time using the Spark view engine, given my background?
You'll need a good understanding of HTML, JavaScript (and jQuery most likely) and CSS for most web work these days. It doesn't matter if you are using ASP.Net MVC w/ Spark, default engine or other technologies like PHP. In the end, the browser only understands HTML, JavaScript and CSS, the other stuff is just to assist in creating that final output, but you still need to understand what you want to be generating.
Regarding view engine, if you are working on learning for future use rather then for an immediate project you want to put into production ASAP, I'd suggest taking a look at Microsoft's upcoming view engine Razor.
http://weblogs.asp.net/scottgu/archive/2010/07/02/introducing-razor.aspx
It is being built for the ASP.Net MVC 3 release taking lessons learned from Spark, NHaml and the default view engine.
From the article:
Design Goals
We had several design goals in mind as we prototyped and evaluated “Razor”:
Compact, Expressive, and Fluid: Razor
minimizes the number of characters
and keystrokes required in a file,
and enables a fast, fluid coding
workflow. Unlike most template
syntaxes, you do not need to
interrupt your coding to explicitly
denote server blocks within your
HTML. The parser is smart enough to
infer this from your code. This
enables a really compact and
expressive syntax which is clean,
fast and fun to type.
Easy to Learn: Razor is easy to learn and enables you to quickly be productive with a minimum of concepts. You use all your existing language and HTML skills.
Is not a new language: We consciously chose not to create a new imperative language with Razor. Instead we wanted to enable developers to use their existing C#/VB (or other) language skills with Razor, and deliver a template markup syntax that enables an awesome HTML construction workflow with your language of choice.
Works with any Text Editor: Razor doesn’t require a specific tool and enables you to be productive in any plain old text editor (notepad works great).
Has great Intellisense: While Razor has been designed to not require a specific tool or code editor, it will have awesome statement completion support within Visual Studio. We’ll be updating Visual Studio 2010 and Visual Web Developer 2010 to have full editor intellisense for it.
Unit Testable: The new view engine implementation will support the ability to unit test views (without requiring a controller or web-server, and can be hosted in any unit test project – no special app-domain required).
For ASP.Net MVC 3 Preview 1, take a look at http://weblogs.asp.net/scottgu/archive/2010/07/27/introducing-asp-net-mvc-3-preview-1.aspx
Specifically on the subject of View Engines, if you're looking to introduce code blocks into your views, then Razor would be the neatest way of doing that.
I guess, given your background, the next question would be - "how do I know if I want to introduce code blocks into the view?" - the answer I'm afraid can only come to you with a lot of pain an experience. Many people have written blog posts explaining the dangers of code blocks mixed in with markup that leads to a nightmare commonly referred to as Tag Soup.
All that Razor (and Webforms for that matter) does for you is bring the power of the entire C# or VB.Net languages into the view in a way that prescribes abundant usage. This is what leads to the Tag Soup problem.
But it seems there are still die-hards out there under some kind of illusion that you can actually keep your views clean in the long term by using this method. If you are working on the code alone, and forever, then I'd tend to agree that it is possible, but only then with the mind-numbingly depressing levels of concentration and determination.
If however, you'd like to keep you views for markup with the code abstracted away to where it can be less tempting to put a "quick fix in here" and a "hack in there", then I'd highly recommend that you skip over the code-centric view engines and go with Spark.
In terms of answering your question directly, you can find plenty of tutorials from beginner to advanced. Here are some of the ones I'd recommend in blog and video formats:
http://blogs.msdn.com/b/coding4fun/archive/2010/10/04/10070953.aspx - An incredibly comprehensive and accurate comparison of View Engines prepared by Jason Haley
http://vimeo.com/13027275 - A beginners' introduction to Spark given at NDC2010 by the author, Lou DeJardin himself
http://vimeo.com/13027900 - Another video for more advanced usage of Spark also given by Lou at the same conference.
http://blog.robertgreyling.com/2010/07/is-razor-just-wolf-in-sparks-clothing.html - A blog post where I directly compare and contrast Razor and Spark
http://blog.robertgreyling.com/2010/08/spark-bindings-are-you-tired-of-eating.html - A blog post I wrote about cleaning up your markup
http://blog.robertgreyling.com/2010/08/elegant-mvc-with-spark-way-views-were.html - An online session I prepared for C4MVC as an educational and awareness exercise.
Anyway, I hope that gives you enough to make an informed decision.
Best of luck in your dabblings!
Rob G
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I decided to start studying code from other developers to improve my coding skills.
I'm looking for a open-source software that uses MVC pattern, and also most design patterns possible.
Could you recommend some open-source software written in C# or VB.NET that uses as many design patters as possible or some code that worth studying?
I would recommend some projects like NServiceBus, which make extensive use of polymorphism (not to mention the NServiceBus API is one of the best APIs I've had the pleasure of using). Also consider something like StructureMap, which uses a model-based configuration API (I actually use Ninject as my IoC of choice, and it could prove to have some interesting code as well). It's hard for me to point out whether or not these projects use specific design patterns, and how many it may use, but I do know that they use some modern APIs and modern approaches to object oriented design.
I would say, though, that your best bet is going to be to find an open source project that you find interesting, or that you use regularly, and crack it open and see what makes it tick. If you are familiar with the details of using the code (whatever it may be), then you will probably gain more insight be looking at the code because you know what it is doing.
I always recommend .NET Domain-Driven Design with C#: Problem-Design-Solution sample code - SmartCA project. It is extremely elegantly laid out and I find myself going back to it whenever I have doubts about my architecture.
You should also download and check out ASP .NET MVC source code. It's got good examples of unit testing and mocking (which is something you will find yourself wanting to use).
I'd recommend checking out the Northwind Starter Kit (http://nsk.codeplex.com/) - it covers off on many design patterns and their application in the .Net framework, including SOA and MVC/MVP/PM concepts. It also includes examples of several other free-to-use libraries, such as Microsoft Entity Framework and NHibernate.
I'm personally particularly pleased with the way they show the same backend can be used with both WPF and ASP.Net.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
In the process of designing an application we've come to the conclusion that the user needs to be available to add custom behaviour to the program and we want to allow this through scripting, however, none of us got any experience embedding a scripting engine in an application and even less designing the application to successfully allow the scripting to place.
We suppose that the key to making the application scriptable is to create a large set of events that the scripts can respond to, as well as exposing functions for the script to use. Instead of rushing into scripting recklessly we would prefer reading up on some resources on the topic.
We're looking for resources (preferably books) which covers the process of designing an application for scripting. Any advice would be awesome as well. More or less any advice on the topic would be nice.
If details of the project in question is needed just say so an I'll add a paragraph explaining more in-depth detail.
How techy do you want to make your scripting?
If your users are happy to use .Net then this artice gives an introduction to making an extensible application.
http://www.developerfusion.com/article/4529/using-net-to-make-your-application-scriptable/
When I was investigating a similar thing a while back I also found the technical notes for the sharpdevelop application to be very helpful.
http://www.icsharpcode.net/TechNotes/ProgramArchitecture.pdf
http://damieng.com/blog/2007/11/08/dissecting-a-c-application-inside-sharpdevelop
Embedding scripting capabilities into an application will depend very much on the language and technology that make up the application. In your case, developing with C# there are some interesting options because of the work on the Dynamic Language Runtime. You should probably take a look at the IronRuby and IronPython projects since they will provide the best overall integration with .NET applications since they are themselves implementations of the Ruby and Python scripting languages on the .NET platform. As my experience centers on Ruby predominantly I would look at the information on hosting IronRuby in a .NET application.
As far as a general book goes I would probably start here: Language Implementation Patterns: Create Your Own Domain-Specific and General Programming Languages. For specifics on IronPython there is this title from Manning: IronPython in Action. And for IronRuby there is this book still in Beta: IronRuby in Action.
This may also be a solid resource coming out of Microsoft's Professional Developer's Conference: Using Dynamic Languages to Build Scriptable Apps.
Can you wait for C# 4.0 and the DLR (or deploy the beta)?
See Application Extensibility and Embedded Scripting.
How hard this is really depends on your requirements. It can be quite easy.
In my app, I built a small set of classes that exposed the basic data model that I wanted to be made available to scripts. I built a scripting manager that creates an instance of the IronPython engine, adds an instance of the data model's root object as a global, and loads and executes the script.
Now, in my case, I'm actually the one doing all the scripting. So I don't need any kind of fancy development environment or testbed application, and I have essentially zero security considerations. The problem would be a lot harder if I needed to worry about any of those things.
Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
What is the quickest/easiest way to learn Java for a seasoned .NET/C# (more than 7 years) and C++ (5years) developer.
When I say to learn Java - I mean being able to write applications in a "Java way" using base classes library + where needed using a popular Java libraries (it is great that so many of them are open source).
I know that Java development comes in a lot of flavors - enterprise applicatons (Java EE), mobile devices (Java ME), objects hosted in application servers (to my knowledge Java has a buch of these) - however at the moment I am interested in a general Java development - may be with a some emphasis on a integration projects/enterprise development.
So basically - I am a strong, passionate about technology, proud to be a senior C#/C++ developer with a dozen years of experience who wants to dedicate a month-worth (may be more) of evenings to learn to effectively program in Java environment.
Having said that I don't mean I am switching from .NET/C++ to Java - but I would probably have to spend 30%-50% of my development time developing/supporting/whateverstageintheSDLC in Java.
Thank you.
I suggest starting with The Java Language Specification. I don't think there is any quicker or more comprehensive way of gaining an understanding of the language for a seasoned programmer.
Followed by Java Collections Tutorial.
Followed by java.lang.* and java.util.* classes, interfaces and packages.
This will give a good basis for learning and understanding any other branch of Java as it becomes necessary.
I would take a completely different approach to reading books upfront. Simply download an IDE and get coding. The netbeans tutorials tend to get you up and running with a variety to technologies very quickly.
If you can code C# then you should have no problem getting something up and running.
Once you have some code up and running that is when you would then dig out the likes of effective Java.
Karl
Effective Java should be in every Java developer's bookshelf. It focuses not so much on performance as one might think from the title, but rather on how to program Java idiomatically, which becomes subtly different from following the idioms of C#.
Perhaps one of the best ways would be to get a copy of Bruce Eckel's Thinking in Java.
Much more than simply covering the syntax of the language, this book goes into the background - as the title says, "How to think in Java" so you can write pure Java code, not C# (or C++) code using Java Syntax.
I m only speaking for java web app development: i think its going to be quite similar to how you might've done it in C# using ASP.NET, except you don't get the visual drag and drop GUI creation using visual studio. The basic concepts are pretty much the same.
As for libraries, there are a million and one in java, and only time will help with those. But it'll help knowing the common ones, such as apache commons, google collections, spring, hibernate. It might help you get started if you start with something like Appfuse, which is a full java RAD web app framework that munges together all the above common frameworks.
On the build tools side, there are ant and maven as the major players. I prefer ant over maven personally.
Ordered list:
Thinking in Java;
Core Java, Volume II;
Spring reference;
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
Last week i searched for good free or opensource solutions and component for GIS (Geographical Information Systems) I founded some system but no one fill my requirements
SharpMap is very buggy software
Gmap.net is very slow
MapWindow have a very complex structure and is very buggy.
I founded uDIG but is in java, i need a solution in vb.net or c#.
Anyone know a good solution that fill my requirements or have alternatives, i accept solutions?
You are limiting yourself a lot by insisting on .NET. I don't know of anything other than SharpMap or MapWinGIS ActiveX (MapWindow). Here are some free, but not .NET, options for Windows desktop applications.
If you'd consider writing your standalone application in Python or C++:
Mapnik
QGIS
Or if you'd consider writing a plug-in or a customisation for an existing GIS:
GRASS can be customised in Python, Perl, Ruby...
QGIS can be customised in Python
I think that you've covered it already. There really aren't any production quality open source GIS project out there using C#. Most of the good work is being done in Java, C/C++ or Python these days. If you must use the .NET Framework then I think the best of the bunch is indeed SharpMap.
Failing that you need to look at commercial products from companies like http://www.esri.com. Of course, it also depends on what you need: web services, Windows Forms control, WPF, etc. In the past I've managed to whip up some C# that constructed the right XML to send to a Java server-based mapping engine, so you could look at something like GeoServer and build your own client. Obviously not what you want to get in to but I don't see that you have many options beyond the ones you've listed.
I would recommend to look in to MapAround
Have you checked out SharpMap? It's available on codeplex.
MapSurfer.NET framework might be a good option.
MapSurfer.NET is free, modern cartographic framework which is able to provide maps of superior cartographic quality. This framework supports a bunch spatial data formats (e.g., Shape files, PostgreSQL, OSM, etc.) and web services (e.g., CartoDB, Mapzen, etc.). Furthermore, its setup includes MapSurfer.NET Studio application which allows creating and editing map styles (analogue of TileMill). Its symbology is inspired by both OGC specifications and other similar toolkits such as MapServer, GeoServer or Mapnik.
We use Mapzania (http://www.mapzania.com).
The best thing about it is that you load it into existing web-applications via a NuGet package and then you get a bunch of GIS functionality.
It uses Leaflet as its front-end and it has JS library that makes it easy to do stuff to Leaflet.
It also has a nice MapStyler for creating and editing maps.