Results 1 to 7 of 7
Thread: Generate a Class file
- 07-05-2007, 05:33 AM #1
Member
- Join Date
- Jun 2007
- Posts
- 91
- Rep Power
- 0
- 07-05-2007, 05:42 AM #2
Senior Member
- Join Date
- Jun 2007
- Posts
- 114
- Rep Power
- 0
Here I pass to you a link detailed with the use of the javac, to compile classes java
javac - Java programming language compiler
Greetings
Albert:rolleyes:
- 04-16-2009, 08:18 AM #3
Member
- Join Date
- Apr 2009
- Posts
- 10
- Rep Power
- 0
Watermark in java class file
Hi
I would like to know how to embed watermark in Java class file and decode that watermark class file to get back the watermark value.
I will be appreciate if any one can provide the source code.
I'hv tried many time to get the bytecode of the class file to embed the watermark value but failed. Should i used the class reader to read the class file but where i must to called the class file and how.
I include some code that i don't know where to get my .class inside this code:
package test;
import javax.swing.JOptionPane;
public class ClassLocationTest {
public static void main(String[] args) {
JOptionPane.showMessageDialog(null, getClassLocation(String.class));
}
public static String getClassLocation(final Class<?> pClass) {
final String location, name;
name = pClass.getName().replaceAll("\\.", "/") + ".class";
location = ClassLoader.getSystemResource(name).getPath();
return location;
}
}
I hope any one can help me immediately because i must to submit it next week.
Thanks you
Azura
- 04-16-2009, 08:37 AM #4
Member
- Join Date
- Jan 2008
- Posts
- 31
- Rep Power
- 0
How very odd, Fist I made a makeClass.bat file in it there is just one line.
"C:\Program Files\Java\jdk1.5.0_02\bin\javac" whatever.java -Xstdout error.txt
and I click onto that batch file to make my class
But I was just thinking WHAT IS WRONG WITH JAVA?
Surly we should be able to make a MakeClass.class file, this keeps track of your latest java projects and keeps the information in a project.txt file so you scroll through previous projects you could then have options if you want to save the error notes to a error.txt file or whatever options there are, and then that file just sends off the "whatever.java -Xstdout error.txt" to the javac file, if fact this might be a good project for someone like me that needs to learn more java.Last edited by tghn2b; 04-16-2009 at 08:39 AM. Reason: forgot the third line of text
- 04-16-2009, 12:41 PM #5
Member
- Join Date
- Apr 2009
- Posts
- 10
- Rep Power
- 0
how to make a .bat file?
- 04-16-2009, 08:38 PM #6
Member
- Join Date
- Jan 2008
- Posts
- 31
- Rep Power
- 0
a number of ways I normally right click my mouse then go for the New option then pick out Text Document
put in your ... javac whatever.java ... close and save or save and close, rename file to makeClass.bat
then you just double click on to it.
----- more -----
you could use a word processor program but you have to be careful it saves as a DOS type text file.
++++++++++++
To edit:
I use Metapad (a few download) metapad download from metapad download
and have added metapad to my list "right click" "send to" options
reason for edit:
trying to add in metapad download because if you print off this page for later the URL is next to uselessLast edited by tghn2b; 04-16-2009 at 08:49 PM. Reason: trying to add in http://liquidninja.com/metapad/download.html because if you print off this page for later the URL is next t
- 04-20-2009, 05:37 AM #7
Member
- Join Date
- Apr 2009
- Posts
- 10
- Rep Power
- 0
Similar Threads
-
Class is public, should be declared in a file
By goldhouse in forum New To JavaReplies: 7Last Post: 05-10-2012, 09:17 AM -
Generate an executable file
By romina in forum New To JavaReplies: 1Last Post: 08-07-2007, 05:30 AM -
Exception Failed to Generate Wrapper Class on WebLogic
By christina in forum New To JavaReplies: 1Last Post: 08-07-2007, 02:15 AM -
Convert my class file into a exe file
By carl in forum New To JavaReplies: 1Last Post: 08-05-2007, 08:35 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks