Solved

IDL/CORBA Compiler.

Posted on 2000-02-18
7
1,152 Views
Last Modified: 2008-03-03
Hi,
I am new in IDL/CORBA programming. I have downloaded "idltojava" compiler from the following site:
http://developer.java.sun.com/developer/earlyAccess/jdk12/idltojava.html

I wanted to compile the following StockMarket.idl program but it is giving error. I am working on Windows95.
Please let me know how to fix the problem.
Thanks,
sunanda
*******StockMarket.idl*********
module StockMarket {                                       typedef string StockSymbol;                                      
typedef sequence<StockSymbol> StockSymbolList;                  
                                                                 
interface StockServer {                                          
                                                                 
float getStockValue(in StockSymbol symbol);                      
                                                                 
StockSymbolList getStockSymbols();                              
                                                                 
};                                                              
                                                                 
};                                                              
                                        ********************************                        


 
0
Comment
Question by:skundu
  • 4
  • 3
7 Comments
 
LVL 8

Expert Comment

by:diakov
ID: 2536694
What error did you get?

I compiled under jacorb and it did work.

module StockMarket
{

typedef string StockSymbol;                                      
typedef sequence<StockSymbol> StockSymbolList;                    
                                                                 
  interface StockServer
  {
    float getStockValue(in StockSymbol symbol);                      
    StockSymbolList getStockSymbols();                                
  };                                                                
};


There is nothing wrong with your idl.

Also what version of the idltojava do you use?

Cheers,
  Nik
0
 

Author Comment

by:skundu
ID: 2549150
Hi,

Thanks for help. This is JDK Version 1.2 Beta 2.
Here is the error:
In the MS-DOS prompt I enter:
idltojava-ea-win32 stockmarket.idl
It shows:
Archive: C:\download\idltojava-ea-win32.exe
caution: filename not matched: StockMatket.idl

Pls let me know (it is not the mismatch of the .idl file name, I entered and that exists, for sure).
thanks,
sunanda
0
 
LVL 8

Accepted Solution

by:
diakov earned 30 total points
ID: 2549424
Look my friend,

idltojava-ea-win32.exe is the archive of the idltojava compiler. Once you run it without parameters it will extract the real compiler and a couple of other files.
As I said, your IDL file is just fine, just extract the program first.

Nik
0
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

 

Author Comment

by:skundu
ID: 2556531
Hi,
Thanks again, but I am still having problem! I run the file idltojava-ea-win32.exe and it created a folder named idltojava-win32. The folder contains one file named idltojava-ea-win32.exe
when I run it like
>idltojava stockmarket.idl
It shows error again:
idltojava-ea-win32.exe: fatal error:
cannot preprocess input; No such file or directory.

Please help me fix it.Thanks.
sunanda
0
 
LVL 8

Expert Comment

by:diakov
ID: 2557114
you have to run with the following flag:
idltojava -fno-cpp test.idl

This turns off the preprocessor that deals with #include, #define, #undef

Cheers,
  Nik
0
 
LVL 8

Expert Comment

by:diakov
ID: 2557116
You can read about the other flags from the two html files that come out of the package.
0
 

Author Comment

by:skundu
ID: 2558899
Thanks.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
servlet doXXX methods 3 62
print map entry 34 72
jsp login check 12 43
What's wrong with this code? 4 26
Java Flight Recorder and Java Mission Control together create a complete tool chain to continuously collect low level and detailed runtime information enabling after-the-fact incident analysis. Java Flight Recorder is a profiling and event collectio…
In this post we will learn how to connect and configure Android Device (Smartphone etc.) with Android Studio. After that we will run a simple Hello World Program.
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question