Visual J Sharp
Visual J# (pronounced "jay-sharp") is a discontinued implementation of the J# programming language that was a transitional language for programmers of Java and Visual J++ languages, so they could use their existing knowledge and…
≈ 9 min read
Visual J Sharp. encyclopegia.org, snapshot enwiki-001360411592. /a/visual-j-sharp
Names in other languages
No names in other languages are held for this entry yet.
Article bodies are English and are not machine-translated. A name in another language is not a translation of the article.
Visual J# (pronounced "jay-sharp") is a discontinued implementation of the J# programming language that was a transitional language for programmers of Java and Visual J++ languages, so they could use their existing knowledge and applications with the .NET Framework.[2][3] It was introduced in 2002[4] and discontinued in 2007, with support for the final release of the product continuing until October 2017.
J# worked with Java bytecode as well as source so it could be used to transition applications that used third-party libraries, even if their original source code was unavailable.[citation needed] It was developed by the Hyderabad-based Microsoft India Development Center at HITEC City in India.[5][6]
The implementation of Java in Visual J++, MSJVM, did not pass Sun's compliance tests leading to a lawsuit from Sun, Java's creator, and creation of J#. Microsoft ceased such support for the MSJVM on December 31, 2007 (later Oracle bought Sun, and with it Java and its trademarks). Microsoft however, officially started distributing Java again in 2021 (though not bundled with Windows or its web browsers as before with J++), i.e. their build of Oracle's OpenJDK,[7] which Microsoft plans to support for at least 6 years, for LTS versions, i.e. to September 2027 for Java 17.
Fundamental differences between J# and Java
edit edit sourceJava and J# use the same general syntax but there are non-Java conventions in J# to support the .NET environment. For example, to use .NET "properties" with a standard JavaBean class, it is necessary to prefix getter and setter methods with the Javadoc-like annotation:
/** @beanproperty */...and change the corresponding private variable name to be different from the suffix of the getXxx/setXxx names[citation needed].
J# does not compile Java-language source code to Java bytecode (.class files), and does not support Java applet development or the ability to host applets directly in a web browser, although it does provide a wrapper called Microsoft J# Browser Controls for hosting them as ActiveX objects. Finally, Java Native Interface (JNI) and raw native interface (RNI) are substituted with P/Invoke; J# does not support remote method invocation (RMI).[8]
InfoWorld said: "J#'s interface to the .NET framework is solid, but not as seamless as C#. In particular, J# code cannot define new .NET attributes, events, value types, or delegates. J# can make use of these language constructs if they are defined in an assembly written in another language, but its inability to define new ones limits J#'s reach and interoperability compared to other .NET languages."[9]
Contrariwise, Microsoft documentation for Visual Studio 2005 details the definition of .NET delegates,[10] events,[11] and value types[12] directly in J#.
Like C# and unlike Java, J# is able to use the C preprocessor directives.
History of J#
edit edit sourceIn January 2007, Microsoft announced:[13]
- That Microsoft would produce an updated version of Visual J# 2.0, including a 64-bit redistributable version, called J# 2.0 Second Edition to meet customer demand for 64-bit runtime support. Microsoft released Visual J# 2.0 Second Edition in May 2007.[14]
- Retirement of the J# language and Java Language Conversion Assistant from future versions of Visual Studio. The last version, shipping with Visual Studio 2005, was supported until 2015.
- Calling J# code from .NET 4.0 code would fail unless vjsnativ.dll was pre-loaded.[15]
The download of Visual J# 2005 Express Edition is no longer available from Microsoft's website.
Visual J# is out of support including the Visual J# 2.0 Redistributable Second Edition released in 2007, that was supported through to 2017 "(5 years mainstream and 5 years extended support) on EN-US locales."[16][17]
Example
edit edit sourceThe following is a simple example of Visual J#.
package Wikipedia.Examples; import System.*; import System.ComponentModel.Container; import System.Drawing.Point; import System.Drawing.Size; import System.Windows.Forms.Application; import System.Windows.Forms.Button; import System.Windows.Forms.Form; import System.Windows.Forms.Label; import System.Windows.Forms.TextBox; public class HelloWorld extends Form { private TextBox textBox; private Button button; private Label label; private Container components = null; public HelloWorld() { InitializeComponent(); } protected void Dispose(boolean disposing) { if (disposing) { components.Dispose(); } super.Dispose(disposing); } private void onClick(Object sender, EventArgs e) { label.set_Text(String.Format("Inputted text: {0}", textBox.get_Text()); } #region Windows Form Designer generated code private void InitializeComponent() { this.textBox = new TextBox(); this.button = new Button(); this.label = new Label(); this.SuspendLayout(); // initialise text box textBox.set_Location(new Point(50, 30)); textBox.set_Name("Hello world!"); textBox.set_Size(new Size(120, 20)); // initialise button button.set_Location(new Point(50, 60)); button.set_Name("button"); button.set_Text("Click me!"); button.add_Click(new EventHandler(this.onClick)); // initialise label label.set_Location(new Point(50, 90)); label.set_Name("label"); label.set_Size(new Size(200, 20)); // initialise form set_AutoScaleBaseSize(new Size(6, 15)); set_ClientSize(new Size(220, 140)); get_Controls().Add(textBox); get_Controls().Add(button); get_Controls().Add(label); set_Name("form"); set_Text("Hello, world!"); ResumeLayout(false); } #endregion /** @attribute System.STAThread() */ public static void main(String[] args) { Application.Run(new HelloWorld()); } }See also
edit edit source- IKVM – a free implementation of Java for Mono and .NET Framework
References
edit edit source- ^ "New and Upgraded Features in Visual Studio .NET 2003". learn.microsoft.com. Microsoft Learn. 22 October 2019. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Visual J# Home". msdn.microsoft.com. Retrieved 2017-03-24. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Java to .NET Framework Migration Workshop: Free Online Training". 30 April 2007. Archived from the original on 2008-04-23. Retrieved 2020-01-28.
{{cite web}}: CS1 maint: bot: original URL status unknown (link) Wikipedia revision 1360411592, retrieved 2026-11-20 - ^ Microsoft News, [1], 1 July 2002 Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ S Prasanna, Microsoft's VJ#.Net is made in India, Express Computer, 29 July 2002 Archived 28 November 2013 at the Wayback Machine Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "The Hindu Business Line : Microsoft lines up big plans for Hyderabad centre". www.thehindubusinessline.com. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Announcing General Availability of Microsoft Build of OpenJDK". Java at Microsoft. 2021-05-25. Retrieved 2021-08-03. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Visual J# Migration". Visual Studio 2005. MSDN Library. Archived from the original on 2012-03-16. Retrieved 2021-12-25. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ Yager, Tom (21 November 2001). "Just don't call J# Java". InfoWorld. Retrieved 2020-07-20. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "delegate (Visual J#)". Visual Studio 2005. MSDN Library. Archived from the original on 2011-12-19. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Definition and Use of Events". Visual Studio 2005. MSDN Library. Archived from the original on 2011-12-19. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "User-Defined Value Types". Visual Studio 2005. MSDN Library. Archived from the original on 2011-12-20. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ Microsoft Developer Network, Visual J# Product Announcement, 10 January 2007 Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Visual J# 2.0 Second Edition Redistributable Download". Microsoft. Archived from the original on 2007-05-23. Retrieved 2010-04-27.
{{cite web}}: CS1 maint: bot: original URL status unknown (link) Wikipedia revision 1360411592, retrieved 2026-11-20 - ^ "Calling J# code from .NET 4.0 - Windward Wrocks". Retrieved 6 March 2017. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "Visual J# Home". Retrieved 6 March 2017. Wikipedia revision 1360411592, retrieved 2026-11-20
- ^ "End of Support for Visual Studio 2008 – in One Year". Retrieved 2017-04-11. Wikipedia revision 1360411592, retrieved 2026-11-20
External links
edit edit source- Official website at the Wayback Machine (archived February 26, 2008)
- Visual J# Design Choices: A Conversation with Pratap Lakshman at the Wayback Machine (archived 2007-04-16)
- ADO.NET
- ASP.NET
- Avalonia
- ClickOnce
- Dynamic Language Runtime
- Extensible Application Markup Language (XAML)
- Language Integrated Query (LINQ)
- Managed Extensibility Framework
- Microsoft Silverlight
- Microsoft XNA
- Parallel Extensions
- Windows Communication Foundation (WCF)
- Windows Forms (WinForms)
- Windows Identity Foundation (WIF)
- Windows Presentation Foundation (WPF)
- Windows Workflow Foundation (WF)
- .NET Remoting
environments
frameworks
debugging
Text derived from https://en.wikipedia.org/w/index.php?oldid=1360411592 under CC BY-SA 4.0; modifications have been made.
References
- ↩Wikipedia “Visual J Sharp” release date (×2) · confidence 0.95 revision URL