Find the path for the loaded class file
To find the path for the loaded class file for your java application use "verbose" java option. Try starting your application like "java -verbose MyClass" and see which class is loaded from which path.
Technology Software Hardware News Tips and Tricks Architecture Yazılım Mimari Bilgisayar Teknoloji Türkçe İngilizce
You can buy any kind of electronic gadgets from DealExtreme with free shipping option.
Please visit DealExtreme for very low prices.
Here is the link to the site : www.dealextreme.com
To find the path for the loaded class file for your java application use "verbose" java option. Try starting your application like "java -verbose MyClass" and see which class is loaded from which path.
zaman:
11/30/2007 03:11:00 pm
0
yorum
You can earn money by clicking Ads. Use me as referrer http://adbux.org/?r=erhan14
Click to join Adbux
zaman:
11/26/2007 10:38:00 am
0
yorum
Floggy is a free object persistence framework for J2ME/MIDP applications.
http://floggy.sourceforge.net/
import net.sourceforge.floggy.persistence.Persistable;
public class Person implements Persistable {
// Static fields aren't persisted
public static int SOME_STATIC_FIELD = 1;
private String name;
private Date birthday;
private char gender;
// Transient fields aren't persisted
private transient int age;
// Each persistable class must have an empty constructor.
public Person() {
// Do something ...
}
...
}
-------------------------------------------------
Person p = new Person();
p.setName(...);
p.setBirthday(...);
p.setGender(...);
try {
// A new object ID is generated.
// You can use it in future operations.
int id = PersistableManager.getInstance().save(p);
} catch (FloggyException e) {
...
}
------------------------------------------------
Person person = new Person();
try {
// To load an object, use the object ID
// generated previously by a save() operation.
PersistableManager.getInstance().load(person, id);
// Now, edit and save the object.
// The same object ID is returned.
person.setName(...);
id = PersistableManager.getInstance().save(person);
} catch (FloggyException e) {
...
}
--------------------------------------------------
zaman:
8/29/2007 08:29:00 am
0
yorum
With the eventual release of Windows Vista and its rumored new 3D graphical desktop capabilities putting it beyond what is presently available for Macintoshes and GNU/Linux, I was left wondering whether any such thing was planned for Linux and when such capabilities would be released.
After a bit of searching I came across Xgl, it is an X server which is layered on top of OpenGL and because of this, it can accelerate drawing operations on the desktop. Xgl takes advantage of the processing power available in modern graphics cards by using their OpenGL drivers to hardware accelerate X, OpenGL and Xvideo applications. In general terms, think of the processing which is put into rendering frames in 3D games and then using that capability to render the humble desktop. What this means is that you get noticeably fast rendering anti-aliased fonts and can perform intricate graphical calculations far faster than other X servers without OpenGL.
XGL Video :
http://www.youtube.com/watch?v=Cz_2vKq5cZk&search=XGL
zaman:
8/17/2007 11:36:00 am
0
yorum
Javolution real-time goals are simple: To make your application faster and more time predictable!
That being accomplished through:
zaman:
7/11/2007 07:55:00 am
0
yorum
Runa WFE is an environment for JBoss jBPM workflow engine. It is a cross-platform end user solution for business process development and execution. Together Runa WFE and JBoss jBPM provide an easy to use business process management system.
http://runawfe.sourceforge.net
zaman:
7/11/2007 07:51:00 am
0
yorum
JCalendarCombo JCascadedPane JDirectoryDialog Split It JCalendarCombo is a very small & simple to use Swing GUI component. It helps the programmers to add date selection functionality to their GUI applications quickly and easily.
JCascadedPane is a Swing GUI library which enables the Java developers to incorporate cascaded panes facility into their applications.
JDirectoryDialog is a Swing GUI library which enables the Java developers to incorporate a directory selection dialog into their applications.
http://in.geocities.com/onlyjava2003/index.html
zaman:
7/11/2007 07:47:00 am
0
yorum
Fanurio time tracking for freelancers v1.6 released
Atelier Software has released Fanurio, a Windows time tracking and billing application designed for freelancers. With Fanurio you can easily organize your work, track time and create invoices.
zaman:
7/11/2007 07:46:00 am
0
yorum
You can export a user's schema from Oracle DB by the following command :
exp user/pwd@SID -owner=user
zaman:
7/04/2007 08:58:00 am
0
yorum
zaman:
5/15/2007 07:46:00 am
0
yorum
If you want to access the Worklist interfaces outside of the Weblogic Server you can use the following code :
Hashtable h = new Hashtable();
h.put(Context.SECURITY_PRINCIPAL, "weblogic");
h.put(Context.SECURITY_CREDENTIALS, "weblogic");
h.put(Context.PROVIDER_URL, "t3://localhost:7001");
h.put(Context.SECURITY_AUTHENTICATION, "simple");
Context ctx = new InitialContext(h);
WorklistContextFactory.getRemoteWorklistContext(ctx, "Your Application Name");
zaman:
5/10/2007 08:55:00 am
0
yorum
You can generate a jar file containing the XMLBean definitions for your XSD schema file from the weblogic workshop 9.2. Right click the XSD you want and select "Web Services" --> "Generate Types JAR File" from the menu. You can use these beans for Web Services or Jpdproxy access.
zaman:
5/04/2007 03:23:00 pm
0
yorum
Connect your Unix, Solaris computer to any Windows, Samba or other SMB/CIFS Server. Sharity is a cross platform network file system mounting Windows shares transparently, just as if they were part of your local hard disk.
http://www.obdev.at/products/sharity/index.html
zaman:
5/04/2007 08:03:00 am
0
yorum
Very impressive movie player :
http://www.subedit.prv.pl/
zaman:
4/19/2007 01:17:00 pm
0
yorum
export LC_ALL=en_US.UTF-8
export LANG=en
Locale Chart for Solaris : http://developers.sun.com/dev/gadc/tools/lc/lc.jsp
zaman:
4/19/2007 11:55:00 am
0
yorum
To open a tar.gz compressed file use the command : "gzip -dc file_name.tar.gz tar -xvf -"
zaman:
4/19/2007 08:21:00 am
0
yorum
TABLESPACE :
create tablespace sample datafile 'C:\oracle\product\10.2.0\oradata\orcl\sample.dbf' size 10M autoextend on next 10M;
USER:
CREATE USER sample IDENTIFIED BY sample DEFAULT TABLESPACE sample TEMPORARY TABLESPACE temp QUOTA UNLIMITED ON sample;
GRANT ALL PRIVILEGES TO sample;
zaman:
4/19/2007 07:52:00 am
0
yorum
To disable someone's MSN Live Messenger tell him to write the following string (without quotes) in the personel messages area : "ñ¯a_Á¯aÿ±m¯aÁÇáç±Çáß±Çá§ÁaÇáDZOÇᯱÇá§±Çár×ÁÇá+ÑÇ á£áÇá"
zaman:
4/19/2007 07:50:00 am
0
yorum
Add the following JVM parameters :
"-Xdebug -Xrunjdwp:transport=dt_socket,address=8888,server=y,suspend=n"
zaman:
4/19/2007 07:49:00 am
0
yorum
The world's smallest and thinnest RFID tags were introduced yesterday by Hitachi. Tiny miracles of miniaturization, these RFID chips (Radio Frequency IDentification chips) measure just 0.05 x 0.05 millimeters.
The previous record-holder, the Hitachi mu-chip, is just 0.4 x 0.4 millimeters. Take a look at the size of the mu-chip RFID tag on a human fingertip.
(Hitachi mu-chip tiny RFID tag)
Now, compare that with the new RFID tags. The "powder type" tags are some sixty times smaller.
(Powder RFID chips next to a human hair)
The new RFID chips have a 128-bit ROM for storing a unique 38 digit number, like their predecessor. Hitachi used semiconductor miniaturization technology and electron beams to write data on the chip substrates to achieve the new, smaller size.
zaman:
2/16/2007 07:53:00 am
0
yorum
Free Download Manager (FDM) is a light-weight, powerful and easy-to-use application. Also this software product is well-known for its intuitive and user-friendly interface. FDM can function as a site manager, accelerator, site explorer and scheduler.
http://www.freedownloadmanager.org/
zaman:
2/07/2007 11:53:00 am
0
yorum
First the Ant build.xml file itself:
<?xml version="1.0" encoding="windows-1252" ?>
<project default="all" xmlns:oracle="antlib:oracle"
xmlns="antlib:org.apache.tools.ant"
xmlns:ivy="antlib:fr.jayasoft.ivy.ant">
<property file="build.properties"/>
<!--
============================================================================
== properties
============================================================================
-->
<!-- directories -->
<property name="src.dir" value="src"/>
<property name="classes.dir" value="classes"/>
<property name="log.dir" value="log"/>
<property name="web.dir" value="public_html"/>
<property name="deploy.dir" value="deploy"/>
<property name="doc.dir" value="doc"/>
<!-- deliverables -->
<property name="webjar.file" value="${app.name}-web.jar"/>
<property name="war.file" value="${app.name}-web.war"/>
<property name="ejbjar.file" value="${app.name}-ejb.jar"/>
<property name="ear.file" value="${app.name}.ear"/>
<!--
============================================================================
== class path
============================================================================
-->
<path id="class.path">
<fileset dir="lib">
<include name="**/*.jar"/>
</fileset>
<pathelement path="${classes.dir}"/>
</path>
<!--
============================================================================
== init
============================================================================
-->
<target name="init">
<tstamp/>
<mkdir dir="${log.dir}"/>
<mkdir dir="${classes.dir}"/>
</target>
<!--
============================================================================
== compile
============================================================================
-->
<target name="compile" depends="init">
<javac srcdir="${src.dir}" destdir="${classes.dir}"
classpathref="class.path"/>
<copy todir="${classes.dir}">
<fileset dir="${src.dir}">
<include name="**/*.xml"/>
<include name="**/*.properties"/>
</fileset>
</copy>
</target>
<!--
============================================================================
== war
============================================================================
-->
<target name="war" depends="compile">
<war destfile="${deploy.dir}/${war.file}" webxml="${web.dir}/WEB-INF/web.xml">
<fileset dir="${classes.dir}">
<include name="**/*.class"/>
<exclude name="test/**/*.class"/>
</fileset>
<fileset dir="${web.dir}">
<include name="**/*.jspx"/>
<include name="**/*.html"/>
<include name="WEB-INF/*.xml"/>
</fileset>
<lib dir="lib">
<exclude name="ivy-1.1.jar"/>
<exclude name="ejb.jar"/>
<exclude name="ejb30.jar"/>
<exclude name="junit.jar"/>
<exclude name="oc4jclient.jar"/>
</lib>
</war>
</target>
<!--
============================================================================
== ejb jar
============================================================================
-->
<target name="ejb" depends="compile">
<jar destfile="${deploy.dir}/${ejbjar.file}">
<fileset dir="${classes.dir}">
<include name="**/model/**/*.class"/>
<exclude name="test/**/*.class"/>
</fileset>
</jar>
</target>
<!--
============================================================================
== Ear
============================================================================
-->
<target name="ear" depends="war,ejb">
<ear destfile="${deploy.dir}/${ear.file}"
appxml="${classes.dir}/META-INF/application.xml">
<fileset dir="${deploy.dir}/" includes="${war.file}"/>
<fileset dir="${deploy.dir}/" includes="${ejbjar.file}"/>
</ear>
</target>
<!--
============================================================================
== deploy
============================================================================
-->
<target name="deploy" depends="init">
<oracle:deploy moduletype="ear" host="${oc4j.host}"
port="${oc4j.admin.port}" userid="${oc4j.admin.user}"
password="${oc4j.admin.password}"
file="${deploy.dir}/${ear.file}"
deploymentname="${app.name}"
logfile="${log.dir}/deploy-ear.log"/>
<oracle:bindWebApp host="${oc4j.host}" port="${oc4j.admin.port}"
userid="${oc4j.admin.user}"
password="${oc4j.admin.password}"
deploymentname="${app.name}" webmodule="${web.name}"
websitename="${oc4j.binding.module}"
contextroot="/${app.name}"
/>
</target>
<!--
============================================================================
== clean
============================================================================
-->
<target name="clean">
<delete quiet="true">
<fileset dir="lib" includes="**/*.jar" excludes="**/ivy-1.1.jar"/>
<fileset dir="${classes.dir}" includes="**/*"/>
<fileset dir="deploy" includes="*"/>
</delete>
</target>
<!--
============================================================================
== deploy
============================================================================
-->
<target name="all" depends="clean,ear,deploy"/>
</project>
Next the build.properties file:
app.name=test1
web.name=test1-web
oc4j.binding.module=default-web-site
oc4j.admin.port=23791
oc4j.admin.user=oc4jadmin
oc4j.http.port=8888
oc4j.admin.password=admin
oc4j.host=localhost
java.home=c:\\Program Files\\Java\\jdk1.5.0_01
oracle.home=c:\\programs\\oracle\\oc4j1013-dp4
And finally a shell script to start ant.
set JAVA_HOME=c:\Program Files\Java\jdk1.5.0_01
set ANT_HOME=c:\programs\oracle\oc4j1013-dp4\ant
set ORACLE_HOME=c:\programs\oracle\oc4j1013-dp4
set PATH=%JAVA_HOME%\bin;%ANT_HOME%\bin;%PATH%
%ANT_HOME%\bin\ant %1 %2 %3
zaman:
2/06/2007 08:40:00 am
0
yorum
Many applications need to use a large number of checkboxes to track options or selected items. To help with this, Struts provides the multibox control. It's quite handy but a little tricky to understand at first.
The multibox leverages the way HTML handles checkboxes. If the box is not checked, the browser does not submit a value for the control. If the box is checked, then the name of the control and its value are submitted. This behavior is the reason there
is a reset() method on the ActionForm. Since the browser will never signal that a box has been un-checked, the only solution is to reset all the boxes, and then check the ones that are now present in the request.
The multibox control is designed to use an array of Strings. Each element in the array represents a checked box. To check a box, add a String to the array with the box's value. To uncheck a box, remove the element from the array. (Sound familiar?)
When passed a value, the multibox control scans the elements of its array to see if there is a match. If so, the box is checked. If not, the box is left unchecked. If the user checks the box and submits the form, the box's value will be included in the
request. The controller will then add that box to the "checked" array. If a box is unchecked, nothing is submitted, and nothing is added to the array. If the ActionForm bean is kept in the session context, in between requests, the reset() method
needs to reduce the array to zero length (but not null).
In this example,
<logic:iterate id="item" property="items">
<html:multibox property="selectedItems">
<bean:write name="item"/>
</html:multibox>
<bean:write name="item"/>
</logic:iterate>
The labels for the individual checkboxes is in the items property. The list of selected items is in an array named selectedItems. Items that are not selected are not present in the selectedItems array. The multibox checks the selectedItems array for
the current item. If it is present, it writes a checked checkbox. If not, it writes an unchecked checkbox.
Given an ActionForm setup like this
private String[] selectedItems = {};
private String[] items = {"UPS","FedEx","Airborne"};
public String[] getSelectedItems() {
return this.selectedItems;
}
public void setSelectedItems(String[] selectedItems) {
this.selectedItems = selectedItems;
}
The markup in the example would generate three checkboxes, labeled UPS, FedEx, and Airborne.
<input type="checkbox" name="selectedItems" value="UPS">UPS
<input type="checkbox" name="selectedItems" value="FedEx">FedEx
<input type="checkbox" name="selectedItems" value="AirBorne">AirBorne
Initially, the selectedItems array would be empty. If UPS were checked and submitted, it would become the equivalent of
private String[] selectedItems = {"UPS"};
If UPS and Airborne were both checked, it would become the equivalent of
private String[] selectedItems = {"UPS","Airborne"};
And when the checkboxes are rendered, the appropriate elements are automagically checked by the multibox tag.
<input type="checkbox" name="selectedItems" value="UPS" checked="checked">UPS
<input type="checkbox" name="selectedItems" value="FedEx">FedEx
<input type="checkbox" name="selectedItems" value="AirBorne" checked="checked">AirBorne
To provide different sets of labels and values, the standard LabelValueBean class [org.apache.struts.util.LabelValueBean] (since 1.1) can be used with the multibox control.
<logic:iterate id="item" property="items">
<html:multibox property="selectedItems">
<bean:write name="item" property="value"/>
</html:multibox>
<bean:write name="item" property="label"/>
</logic:iterate>
zaman:
2/06/2007 08:29:00 am
0
yorum
Members of the open source GPE project (GPE Palmtop Environment) today announced a new offspring project to create a fully open source software stack for mobile phones, GPE Phone Edition. GPE Phone Edition is a fully open source project based on developments from the GPE project adding necessary components for mobile phone usage. Based on standards defined by the LiPS Forum a complete application software stack is built. The current implementation is based on code contributed to the LiPS Forum by Orange/France Telecom's research and development lab located in Beijing China in collaboration with GPE project members. The result is now an open sourced software stack which can handle a GSM compliant mobile modem for making voice calls, handling the SIM address book and sending and receiving SMS. Also some additional application exists e.g. for media playback, instant messaging and email. They have some screenshots there and even a downloadable VMware image using which you can try the whole thing in a virtual phone on your PC — if you connect a GSM Modem (like an existing phone) to /dev/GSM-Modem you should probably even be able to use the full phone functionality (access SIM card, send/receive SMS, make a call!).
zaman:
2/06/2007 08:17:00 am
0
yorum