Login | Register   
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX


advertisement
 

Connecting CORBA to .NET : Page 3

In this article, you'll see how to build a CORBA server and connect it to C# clients using Borland's Janeva as "glue".


advertisement
Figure 5. C#Builder New C# Application Wizard: You use this wizard to specify the name and location of the new project.

Build a CORBA Client
I've used C#Builder to create this .NET CORBA client in C#, but the concepts work equally well with any .NET language. Start C#Builder Enterprise or Architect, and create a new C# application. In the New Application dialog you can specify the name as well as the location of the new project (see Figure 5).

Borland Janeva 1.0
Borland Janeva delivers seamless, high-performance interoperability between Microsoft .NET Framework applications and J2EE/CORBA server objects. The Enterprise and Architect editions of C#Builder Enterprise both include Janeva, but you can also download Janeva separately from the Borland Web site (and use it with other .NET development environments—see the end of this article for more information).

Figure 6. Add CORBA Reference: Janeva adds two items to the Add References menu, letting you select J2EE or CORBA references as well as standard file or Web references.

After the free registration, you get a development license from Borland that's suitable for testing purposes; however, you must purchase a deployment license before you can deploy .NET clients you create (see the Janeva documentation itself for more details).

After installing Janeva, you can right-click on the main project file inside the Project Manager in C#Builder, and add a J2EE or CORBA Reference (see Figure 6). Without Janeva, you can add only regular references (normal files) or Web references (Web services) to the project.

Because the example project is a CORBA server, select the Add CORBA Reference item, which then displays a dialog where you can specify the IDL file that holds the CORBA server definition—in this case DiarySrv.idl (see Figure 7).

CORBA Server applications publish their "interface" definition using these Interface Definition Language (IDL) files. Development environments supporting CORBA client applications usually offer support to convert the IDL to native computer languages such as C++ or Java. For a .NET client, however, some process must convert the IDL to a .NET language, such as VB.NET or C#. This IDL-to-C# (IDL2CS) conversion is a welcome Borland Janeva feature.



Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap