Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > Help for Generating .h file

Reply
Thread Tools

Help for Generating .h file

 
 
srinivas.veeranki@gmail.com
Guest
Posts: n/a
 
      01-10-2007
Hi all,

I am unable generate the .h file. I want 2 generate .h file for the
following class.

Here SystemAgent and NodeAgent are also in the same package. But its
not recognising. While I am generating i am getting the following
Error.


D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
p\f2j\SystemMonitor>javah -jni EnvironmentAgent
Error: Class com.oxhp.f2j.SystemMonitor.SystemAgent could not be found.


package com.oxhp.f2j.SystemMonitor;

import com.gtl.ftoj.framework.TextData;

public class EnvironmentAgent extends SystemAgent
{
public native void AlertToSystem(TextData subject, TextData message,
int type, int serviceId ,int group ,int level );

public native void AlertToSystem(TextData subject, TextData message,
int type , int serviceId, int group);

public native void AlertToSystem(TextData subject, TextData message,
int type , int serviceId);

public native void AlertToSystem(TextData subject, TextData message,
int type );

public native NodeAgent GetNodeAgent();

}

Thanks 4 ur help in advance..........


Thanks & Regards,

Srinivas.

 
Reply With Quote
 
 
 
 
Gordon Beaton
Guest
Posts: n/a
 
      01-10-2007
On 10 Jan 2007 03:41:21 -0800, http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
> Here SystemAgent and NodeAgent are also in the same package. But its
> not recognising. While I am generating i am getting the following
> Error.
>
> D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
> p\f2j\SystemMonitor>javah -jni EnvironmentAgent
> Error: Class com.oxhp.f2j.SystemMonitor.SystemAgent could not be found.


Some clues:

- The necessary classes must be compiled (with javac) before you run
javah.

- Specify a classpath that points to the *root* of your package
structure. Replace "..." in my example below with the correct
path.

- *Always* specify the fully qualified classname when using javah.

- It isn't necessary to specify "-jni".

Your command line should look something like this:

javah -classpath D:/.../oxhp_fortebatch/src com.oxhp.f2j.SystemMonitor.EnvironmentAgent

/gordon

--
[ don't email me support questions or followups ]
g o r d o n + n e w s @ b a l d e r 1 3 . s e
 
Reply With Quote
 
 
 
 
srinivas.veeranki@gmail.com
Guest
Posts: n/a
 
      01-10-2007
Hi,

Here all classes are compie free.

D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
p\f2j\SystemMonitor>javah -classpath
D:\OXHP_FORTEBATCH\CustomerDeliverables\Fir
stRelease\oxhp_fortebatch\src
com.oxhp.f2j.SystemMonitor.EnvironmentAgent
Error: Class com.gtl.ftoj.framework.ForteObject could not be found.



Gordon Beaton wrote:
> On 10 Jan 2007 03:41:21 -0800, (E-Mail Removed) wrote:
> > Here SystemAgent and NodeAgent are also in the same package. But its
> > not recognising. While I am generating i am getting the following
> > Error.
> >
> > D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
> > p\f2j\SystemMonitor>javah -jni EnvironmentAgent
> > Error: Class com.oxhp.f2j.SystemMonitor.SystemAgent could not be found.

>
> Some clues:
>


Here all classes are compile free...

> - The necessary classes must be compiled (with javac) before you run
> javah.
>


D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
p\f2j\SystemMonitor>javah -classpath
D:\OXHP_FORTEBATCH\CustomerDeliverables\Fir
stRelease\oxhp_fortebatch\src
com.oxhp.f2j.SystemMonitor.EnvironmentAgent
Error: Class com.gtl.ftoj.framework.ForteObject could not be found.

I used the javah command like in the following way.. I got the above
specified Error.

Thanks for ur reply... Plz give me the reply...
> - Specify a classpath that points to the *root* of your package
> structure. Replace "..." in my example below with the correct
> path.
>
> - *Always* specify the fully qualified classname when using javah.
>
> - It isn't necessary to specify "-jni".
>
> Your command line should look something like this:
>
> javah -classpath D:/.../oxhp_fortebatch/src com.oxhp.f2j.SystemMonitor.EnvironmentAgent
>
> /gordon
>
> --
> [ don't email me support questions or followups ]
> g o r d o n + n e w s @ b a l d e r 1 3 . s e


 
Reply With Quote
 
srinivas.veeranki@gmail.com
Guest
Posts: n/a
 
      01-10-2007
Hi, SystemAgent Class is like this

package com.oxhp.f2j.SystemMonitor;

import java.io.FileWriter;

import javax.sound.midi.Instrument;

import com.gtl.ftoj.framework.ClassType;
import com.gtl.ftoj.framework.ForteObject;
import com.gtl.ftoj.framework.LargeArray;
import com.gtl.ftoj.framework.TextData;


public class SystemAgent extends ForteObject
{
public SystemAgent getParentAgent()
{
return ParentAgent;
}
public void setParentAgent(SystemAgent agent)
{
ParentAgent = agent;
}


public native void AddInstrument(Instrument inst);

public native void AddSubAgent(SystemAgent subAgent, AgentInfo
subAgentInfo);

public native void AttachMO(ForteObject managedObject);

public native boolean CheckAndSetState(int state);

public native boolean CheckState(int state);

public native void DeleteInstrument(Instrument inst);

public native void DeleteSubAgent(SystemAgent subAgent);
-------------

}




(E-Mail Removed) wrote:
> Hi,
>
> Here all classes are compie free.
>
> D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
> p\f2j\SystemMonitor>javah -classpath
> D:\OXHP_FORTEBATCH\CustomerDeliverables\Fir
> stRelease\oxhp_fortebatch\src
> com.oxhp.f2j.SystemMonitor.EnvironmentAgent
> Error: Class com.gtl.ftoj.framework.ForteObject could not be found.
>
>
>
> Gordon Beaton wrote:
> > On 10 Jan 2007 03:41:21 -0800, (E-Mail Removed) wrote:
> > > Here SystemAgent and NodeAgent are also in the same package. But its
> > > not recognising. While I am generating i am getting the following
> > > Error.
> > >
> > > D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
> > > p\f2j\SystemMonitor>javah -jni EnvironmentAgent
> > > Error: Class com.oxhp.f2j.SystemMonitor.SystemAgent could not be found.

> >
> > Some clues:
> >

>
> Here all classes are compile free...
>
> > - The necessary classes must be compiled (with javac) before you run
> > javah.
> >

>
> D:\OXHP_FORTEBATCH\CustomerDeliverables\FirstRelea se\oxhp_fortebatch\src\com\oxh
> p\f2j\SystemMonitor>javah -classpath
> D:\OXHP_FORTEBATCH\CustomerDeliverables\Fir
> stRelease\oxhp_fortebatch\src
> com.oxhp.f2j.SystemMonitor.EnvironmentAgent
> Error: Class com.gtl.ftoj.framework.ForteObject could not be found.
>
> I used the javah command like in the following way.. I got the above
> specified Error.
>
> Thanks for ur reply... Plz give me the reply...
> > - Specify a classpath that points to the *root* of your package
> > structure. Replace "..." in my example below with the correct
> > path.
> >
> > - *Always* specify the fully qualified classname when using javah.
> >
> > - It isn't necessary to specify "-jni".
> >
> > Your command line should look something like this:
> >
> > javah -classpath D:/.../oxhp_fortebatch/src com.oxhp.f2j.SystemMonitor.EnvironmentAgent
> >
> > /gordon
> >
> > --
> > [ don't email me support questions or followups ]
> > g o r d o n + n e w s @ b a l d e r 1 3 . s e


 
Reply With Quote
 
Gordon Beaton
Guest
Posts: n/a
 
      01-10-2007
On 10 Jan 2007 04:18:25 -0800, (E-Mail Removed) wrote:
> Error: Class com.gtl.ftoj.framework.ForteObject could not be found.
>
> I used the javah command like in the following way.. I got the above
> specified Error.


So now it complains about a different missing class. Apparently you
need to provide more paths in the classpath entry. Separate them with
semicolons.

/gordon

--
[ don't email me support questions or followups ]
g o r d o n + n e w s @ b a l d e r 1 3 . s e
 
Reply With Quote
 
srinivas.veeranki@gmail.com
Guest
Posts: n/a
 
      01-10-2007
Hi Gordon ,

Thank you Mr.Gordon. I did it finally. I specified all the jar files in
the class path which are in my lib folder. Then I got it.

Thanks for ur help.

Thanks & Regards,

Srinivas.


Gordon Beaton wrote:
> On 10 Jan 2007 04:18:25 -0800, (E-Mail Removed) wrote:
> > Error: Class com.gtl.ftoj.framework.ForteObject could not be found.
> >
> > I used the javah command like in the following way.. I got the above
> > specified Error.

>
> So now it complains about a different missing class. Apparently you
> need to provide more paths in the classpath entry. Separate them with
> semicolons.
>
> /gordon
>
> --
> [ don't email me support questions or followups ]
> g o r d o n + n e w s @ b a l d e r 1 3 . s e


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ASP.net/VB.net generating gibberish in file write. Merennulli ASP .Net 1 02-22-2006 11:01 PM
Generating a "virtual file" Mark Rendle ASP .Net 4 06-20-2005 11:10 AM
Need Help in generating PPT file in ASP .NET Chenna Sudarsan ASP .Net 1 05-30-2005 08:09 PM
generating a .js file with asp.net WL ASP .Net 5 07-07-2004 07:59 PM
encoding="UTF-8" being deleted when generating file from DOM Mike Kennedy XML 3 11-29-2003 10:12 PM



Advertisments