Missing webservices jar files in 9.0.2
Hi,
I am trying to deploy webserivces using stateless java class on oc4j version 9.0.2 but i do not have appropriate jar files. Only following jars are installed.
%OC4J_INSTALL%\j2ee\home\WebServicesAssembler.jar
%OC4J_INSTALL%\j2ee\home\WebServicesHtmlXmlWizard.jar
%OC4J_INSTALL%\j2ee\home\wsdl2ejb.jar
%OC4J_INSTALL%\soap\lib\wsdl.jar
The environment is windows 2000.
How can I get appropriate jar files to enable webservices on my installation of oc4j version 9.0.2.0.1
Thanks
Salman
Could you elaborate on what you are missing? On a default OC4J install, downloadable here on OTN, everything is there ... I can point out what you need to locate but am not sure what you see missing or what error messages are leading you to not find classes.
For example, the soap.jar is normally in the <oc4j_home>\soap\lib\ directory. In the <oc4j_home>\lib and <oc4j_home>\jlib there are also other supporting jars.
Thanks.
Mike.
Similar Messages
-
Building the webservice jar file
I have a problem with the underlying errormsg. Could anyone help.
Below the errormsg i have included the content of the jar file, where ant claims
ejb-jar.xml missing. (I've even given full rights to the files before packing in
jar).
Thanx in advance!
Michael Nielsen
Buildfile: build.xml
webservice:
clean:
init:
[mkdir] Created dir: /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build
[mkdir] Created dir: /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build/META-INF
[copy] Copying 3 files to /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build/META-INF
compile_ejb:
jar_ejb:
[jar] Building jar: /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/a_statelessSession.jar
ejbc:
[java] java.io.FileNotFoundException: META-INF/ejb-jar.xml not found in jar
file
[java] at weblogic.ejb20.dd.xml.DDUtils.getEntry(DDUtils.java:332)
[java] at weblogic.ejb20.dd.xml.DDUtils.getEjbJarXml(DDUtils.java:236)
[java] at weblogic.ejb20.dd.xml.DDUtils.loadEJBJarDescriptorFromJarFile(DDUtils.java:151)
[java] at weblogic.ejb20.dd.xml.DDUtils.createDescriptorFromJarFile(DDUtils.java:139)
[java] at weblogic.ejb20.dd.xml.DDUtils.createDescriptorFromJarFile(DDUtils.java:130)
[java] at weblogic.ejbc20.runBody(ejbc20.java:338)
[java] at weblogic.utils.compiler.Tool.run(Tool.java:79)
[java] at weblogic.ejbc.main(ejbc.java:21)
[java] ERROR: java.io.FileNotFoundException: META-INF/ejb-jar.xml not found
in jar file
[java] Java Result: 1
all:
wsgen:
BUILD FAILED
/home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build-ws.xml:12:
Could not create task of type: wsgen. Common solutions are to use taskdef to declare
your task, or, if this is an optional task, to put the optional.jar in the lib directory
of your ant installation (ANT_HOME).
CONTENT OF THE JAR FILE profil.jar
0 Wed Jul 10 15:17:50 CEST 2002 META-INF/
71 Wed Jul 10 15:17:50 CEST 2002 META-INF/MANIFEST.MF
776 Wed Jul 10 13:39:14 CEST 2002 ProfilVO.class
789 Wed Jul 10 13:39:14 CEST 2002 StamdataVOI.class
442 Wed Jul 10 13:39:12 CEST 2002 EmailVOI.class
509 Wed Jul 10 13:39:10 CEST 2002 AbonnementVOI.class
345 Wed Jul 10 13:39:00 CEST 2002 AdresseVOI.class
455 Wed Jul 10 13:39:10 CEST 2002 InteresseVOI.class
413 Wed Jul 10 13:39:14 CEST 2002 ProfilIF.class
447 Wed Jul 10 13:39:12 CEST 2002 TelefonVOI.class
332 Wed Jul 10 13:39:10 CEST 2002 ProfilHome.class
6966 Wed Jul 10 13:39:10 CEST 2002 ProfilBean.class
1804 Wed Jul 10 14:58:00 CEST 2002 build-ejb.xml
477 Wed Jul 10 13:49:24 CEST 2002 META-INF/weblogic-ejb-jar.xml
918 Wed Jul 10 13:47:54 CEST 2002 META-INF/ejb-jar.xmlHi,
Could you give us a few more details. What version of WLS are U using and if you could turn on -verbose on the ant command
and post the results.
Thanks,
Bruce
Michael Nielsen wrote:
I have a problem with the underlying errormsg. Could anyone help.
Below the errormsg i have included the content of the jar file, where ant claims
ejb-jar.xml missing. (I've even given full rights to the files before packing in
jar).
Thanx in advance!
Michael Nielsen
Buildfile: build.xml
webservice:
clean:
init:
[mkdir] Created dir: /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build
[mkdir] Created dir: /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build/META-INF
[copy] Copying 3 files to /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build/META-INF
compile_ejb:
jar_ejb:
[jar] Building jar: /home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/a_statelessSession.jar
ejbc:
[java] java.io.FileNotFoundException: META-INF/ejb-jar.xml not found in jar
file
[java] at weblogic.ejb20.dd.xml.DDUtils.getEntry(DDUtils.java:332)
[java] at weblogic.ejb20.dd.xml.DDUtils.getEjbJarXml(DDUtils.java:236)
[java] at weblogic.ejb20.dd.xml.DDUtils.loadEJBJarDescriptorFromJarFile(DDUtils.java:151)
[java] at weblogic.ejb20.dd.xml.DDUtils.createDescriptorFromJarFile(DDUtils.java:139)
[java] at weblogic.ejb20.dd.xml.DDUtils.createDescriptorFromJarFile(DDUtils.java:130)
[java] at weblogic.ejbc20.runBody(ejbc20.java:338)
[java] at weblogic.utils.compiler.Tool.run(Tool.java:79)
[java] at weblogic.ejbc.main(ejbc.java:21)
[java] ERROR: java.io.FileNotFoundException: META-INF/ejb-jar.xml not found
in jar file
[java] Java Result: 1
all:
wsgen:
BUILD FAILED
/home/min1210/mille6/classes/dk/dsb/mille/integration/webservice/profil/build-ws.xml:12:
Could not create task of type: wsgen. Common solutions are to use taskdef to declare
your task, or, if this is an optional task, to put the optional.jar in the lib directory
of your ant installation (ANT_HOME).
CONTENT OF THE JAR FILE profil.jar
0 Wed Jul 10 15:17:50 CEST 2002 META-INF/
71 Wed Jul 10 15:17:50 CEST 2002 META-INF/MANIFEST.MF
776 Wed Jul 10 13:39:14 CEST 2002 ProfilVO.class
789 Wed Jul 10 13:39:14 CEST 2002 StamdataVOI.class
442 Wed Jul 10 13:39:12 CEST 2002 EmailVOI.class
509 Wed Jul 10 13:39:10 CEST 2002 AbonnementVOI.class
345 Wed Jul 10 13:39:00 CEST 2002 AdresseVOI.class
455 Wed Jul 10 13:39:10 CEST 2002 InteresseVOI.class
413 Wed Jul 10 13:39:14 CEST 2002 ProfilIF.class
447 Wed Jul 10 13:39:12 CEST 2002 TelefonVOI.class
332 Wed Jul 10 13:39:10 CEST 2002 ProfilHome.class
6966 Wed Jul 10 13:39:10 CEST 2002 ProfilBean.class
1804 Wed Jul 10 14:58:00 CEST 2002 build-ejb.xml
477 Wed Jul 10 13:49:24 CEST 2002 META-INF/weblogic-ejb-jar.xml
918 Wed Jul 10 13:47:54 CEST 2002 META-INF/ejb-jar.xml -
Workshop missing WebLogic jar files
Hello,
I am new to WebLogic and Workshop (version 8.1.4). We are taking over a production code base from a vendor and have attempted to do a build of the .ear file. The build fails with errors. Looking into this, it appears the IDE does not know about the quoted portion of the following import lines:
Package com.bea contains no member package or type of this name. “com.bea.wli”
import com.bea.wli.control.dynamicProperties.DynamicPropertiesDocument.DynamicProperties;
import com.bea.wli.control.dynamicProperties.EmailControlPropertiesDocument;
import com.bea.wli.control.dynamicProperties.EmailControlPropertiesDocument.EmailControlProperties;
import com.bea.wli.control.dynamicProperties.FileControlPropertiesDocument;
Package com.bea contains no member package or type of this name. “com.bea.data”
import com.bea.data.RawData;
The vendor stated that the .jar files might be located on the actual licensed WebLogic server? To reduce the time of this effort, could someone tell me the specific .jar files to go after?
Thank you very much
RobertI should clarify further that the copy of Workshop we are using was pulled down from the archive of BEA downloads. We do not have access to a copy of Workshop as configured by the vendor. Additionally, looking at the *.work file for the Application and comparing the .jar files to my Weblogic (local) install the following are missing:
../../../../bea/weblogic81/server/lib/wli.jar;
../../../../bea/weblogic81/portal/lib/wps_system.jar;
../../../../bea/weblogic81/p13n/lib/p13n_system.jar;
../../../../bea/weblogic81/portal/lib/netuix/system/netuix_system.jar;
My assumption is the issue has to do with the wli.jar above. Can someone tel me where a copy can be obtained?
thank you,
Robert -
Missing EUS_EDir.jar file
Hello
I have installed the following components:
Component
Version
Oracle WebLogic Server
11gR1 (10.3.6)
Oracle Identity Management
11g Patch Set 6 (11.1.1.7.0) for Linux x86-64
I am now trying to integrate OVD with EUS for users stored in Novell eDirectory. Whilst configuring OVD for the Integration, I am getting the following error when I am trying to deploy the EUS_EDir Mapping Template.
Directory Service Manager > Advanced > Mapping Templates > EUS_EDir
Click on Apply
I then get the following error:
jar file /appl/iam/Oracle/Middleware/user_projects/domains/IDMDomain/servers/wls_ods1/tmp/_WL_user/odsm_11.1.1.2.0/z5xils/war/conf//ovdmapping/jars/EUS_EDir.jar does not exist !
Can someone please help.
ThanksAll source and class files are exported into 1 folder (src). I enabled the "use output
folders src/bin" option in Java > Build path. And tried a lot of the options provided
during the exporting of a JAR.This is an Eclipse, rather than an Omondo, problem. And not really a "Java Programming" problem. My intent in saying this is not to put you off, but to suggest that Eclipse may have forums that provide better advice, faster.
Work through any simple, tutorial type, examples that came with Eclipse if you are unfamiliar with it - to see what the options are, and how you would use them.
Check that your project really is using separate src/bin directories, either by checking for the physical files, or from the "Package Explorer" pane. Right click on the project icon and select "Properties". Check under the "Java Build Path" settings that the "Source" tab shows <project name>/src and the default output folder is listed as <project name>/bin.
Check that when you export the jar file, in the "Jar File Specification" pane, that the "Export Java source files and resources" check box is as you want it. -
Missing Orion.jar file when running bc4j-ojsp.zip installation
Hi
I've run into a problem with installing the BC4J runtime kit
once it's unpact and I try to run the bat file it's complaing
that it cannot find the orion.jar file, when i search the c
drive there is no orion.jar file either
anyone got any ideas and or the orion.jar file and some
instructions about where it needs to go ?
regards
MalcolmThe orion.jar file is placed in the ?\j2ee\home directory. If it
is not there reinstall and/or re-download the oc4j.zip file and
unzip again. -
Webservices.jar is missing from WL_HOME/server/lib in WLS 12c
webservices.jar is missing from WL_HOME/server/lib in WLS 12c. Was it replaced by a different jar or is this a new implementation i'm unfamiliar with? It does appear in all versions up to 11g.
Without it i won't be able to migrate my application to 12c from the older versions...hi,
In the 12.1.1 release, the 8.1 WebLogic Web services run time has been removed. So you will no longer see the webservices.jar file
http://docs.oracle.com/cd/E24329_01/web.1211/e24497/upgrade_ws.htm#BGBIDHIJ
Regards,
Sunil P -
Error while compiling Web Dynpro program due to missing JAR files
Hi Experts,
I am getting error message while compiling Web Dynpro program. The erring lines are as below:
Message message = new MimeMessage(session);
try {
message.setFrom(new InternetAddress(fromMailId));
message.addRecipient(
Message.RecipientType.TO,
new InternetAddress(toMailId));
message.setSubject(mailSubject);
message.setText(mailBody);
message.setHeader("X-Mailer", "E-Mail");
message.setSentDate(new Date());
Transport.send(message);
The error messages are:
Message.ReceipientType can not be resolved
The method send(Message) is undefined for the type Transport
The method setFrom(InternetAddress) is undefined for the type Message
The method setHeader(String, String) is undefined for the type MessageThe method setSentDate(Date) is undefined for the type Message
The method setSubject(String) is undefined for the type Message
The method setText(String) is undefined for the type Message
Type mismatch: cannot convert from MimeMessage to Message
Can you please help me in resolving the issue. It seems that some API is missing. I believe if some one can tell me the name of JAR file / API then I will be able to sort out the issue. I will add these JAR file in my program.
Thanks,
SHI Stuart,
you are missing the jar files required for sending mail in java
Installing JavaMail
You will need the latest version of JavaMail (Version 1.2) available here:
http://java.sun.com/products/javamail/
Download and unzip the file, in the newly created top level JavaMail directory you will find a number of jar files,
these need adding to your classpath.
To do this in Eclipse, right click on your project in the tree view, select properties, select the libraries tab.
Now click the 'Add external jars' button, navigate to your JavaMail directory and click on the jars.
The tutorial also makes use of the Java Activation Framework, which is available here:
http://java.sun.com/products/javabeans/glasgow/jaf.html
Instalation of JAF is identical to JavaMail
activation.jar / mail.jar are 2 distinct names i remember rest you will get above
P.S: close the question to assist other users narrow the search and find solutions
Message was edited by:
Armin Reichert -
Hello friends,
I'm trying to integrate TinyMCE editor in our new 7.3 Portal WPC. As part of process, I downloaded the 'How To Integrate the TinyMCE JavaScript Content Editor in Web Page Composer_Code.zip' file and followed instructions. However, my NWDS project is missing following JAR files and I can't find them anywhere.
tc.km.frwk.jar
com.sap.nw.pcc.xmleditor.jar
I checked with my Basis team and they are clueless as well. Could you help me find these jar files? Appreciate your timely help.
Thanks,
Vishwas.Hi
Open the .zip file you downloaded (How To Integrate the TinyMCE JavaScript Content Editor in Web Page Composer_Code.zip or sth like that) with your zip software.
- Chose the Folder: TinyMCEEditorComponent
- Here you find a file called .classpath
- Open this file with your texteditor and delete the following two lines towards the end with:
<classpathentry exported="true" kind="lib" path="//production2.....com.sap.nw.pcc.xmleditor.jar"/>
<classpathentry exported="true" kind="lib" path="//production2...../_kmfrwk/tc~km~frwk.jar"/>
- close the file and save your changes
- now you can import the .zip into your NWDS, make changes when needed and deploy it to your portal
BR
Christophe -
Accessing web application JAR files from applet
I've got an applet which is part of a web application.
All the web application JARs are in the webapps/myappl/WEB-INF/lib directory, and I
can't seem to place anything in that directory on the archive attribute of <OBJECT> tag.
I'm running into trouble because I'm sending objects from the servlet to the applet and keep getting classnot found during deserialization because I've missed some jar file on the archive attribute. I've had to copy lots of jar files up to where the codebase in the HTML file is to make this run. My question is this.
Is it better to just change the tomcat security policy file (catalina.policy in tomcat conf directory) so that the JARs are directly accessible and I don't have to copy them from WEB-INF/lib???? Has anyone done this before? What would the line look like?
I'm assuming that I have to follow the instructions (THAT I DON'T UNDERSTAND)
at the bottom of the policy file. Can someone help me out here????
should I have something like
grant codeBase "file:${catalina.home}/webapps/myappl/WEB-INF/classes/-"
{ permission java.security.AllPermission; };
grant codeBase "file:${catalina.home}/webapps/myappl/WEB-INF/lib/-"
{ permission java.security.AllPermission; };
Will this allow me to place references to jar files (and the classes directory) in the archive attribute, such as
<OBJECT ..... >
<param name="archive" value="../WEB-INF/lib/applet.jar,../WEB-INF/lib/someapp.jar,../WEB-INF/classes" />trailer for catalina.policy is
// You can assign additional permissions to particular web applications by
// adding additional "grant" entries here, based on the code base for that
// application, /WEB-INF/classes/, or /WEB-INF/lib/ jar files.
// Different permissions can be granted to JSP pages, classes loaded from
// the /WEB-INF/classes/ directory, all jar files in the /WEB-INF/lib/
// directory, or even to individual jar files in the /WEB-INF/lib/ directory.
// For instance, assume that the standard "examples" application
// included a JDBC driver that needed to establish a network connection to the
// corresponding database and used the scrape taglib to get the weather from
// the NOAA web server. You might create a "grant" entries like this:
// The permissions granted to the context root directory apply to JSP pages.
// grant codeBase "file:${catalina.home}/webapps/examples/-" {
// permission java.net.SocketPermission "dbhost.mycompany.com:5432", "connect";
// permission java.net.SocketPermission "*.noaa.gov:80", "connect";
// The permissions granted to the context WEB-INF/classes directory
// grant codeBase "file:${catalina.home}/webapps/examples/WEB-INF/classes/-" {
// The permission granted to your JDBC driver
// grant codeBase "file:${catalina.home}/webapps/examples/WEB-INF/lib/driver.jar" {
// permission java.net.SocketPermission "dbhost.mycompany.com:5432", "connect";
// The permission granted to the scrape taglib
// grant codeBase "file:${catalina.home}/webapps/examples/WEB-INF/lib/scrape.jar" {
// permission java.net.SocketPermission "*.noaa.gov:80", "connect";
// };Thank you for your reply.
As I mentioned in my first post I had seen a couple of posts mentioning ServletContext before, but dismissed them as I am not using any servlets of my own. However, since you showed me exactly how it was used I realised I could probably just use a dummy servlet to get this information.
The following page suggests a couple of techniques for doing just this.
http://www.jguru.com/forums/view.jsp?EID=1087411
So I think that's me sorted, cheers. -
We deployed a war-file with a web service. The war file
includes the xbean.jar in the WEB-INF/lib directory. Within the
xbean.jar a version of class javax.xml.namespace.Qname exists with
the constructor
Qname(java.lang.String,java.lang.String,java.lang.String). Our web
service calls this a constructor and terminates with the exception:
java.lang.NoSuchMethodError:
javax.xml.namespace.QName.<init>(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String
I suppose that the QName class is taken from the Jrun's
webservices.jar file. This one includes the Qname class without the
needed constructor (3 string arguments).
How can I configure Jrun so that the xbean.jar's QName is
taken instead of the the webservices.jar's QName.
Regards AndreasYou can use the
<load-system-classes-first>false</load-system-classes-first>
attribute in jrun-web.xml to override the classes shipped
with JRun.
Thanks,
Gurdeep
"goebbi" <[email protected]> wrote in
message
news:e1lmrf$1ot$[email protected]..
> We deployed a war-file with a web service. The war file
includes the
> xbean.jar
> in the WEB-INF/lib directory. Within the xbean.jar a
version of class
> javax.xml.namespace.Qname exists with the constructor
>
Qname(java.lang.String,java.lang.String,java.lang.String). Our web
service
> calls this a constructor and terminates with the
exception:
> java.lang.NoSuchMethodError:
>
javax.xml.namespace.QName.<init>(Ljava/lang/String;Ljava/lang/String;Ljava/lang/
> String
>
> I suppose that the QName class is taken from the Jrun's
webservices.jar
> file.
> This one includes the Qname class without the needed
constructor (3 string
> arguments).
>
> How can I configure Jrun so that the xbean.jar's QName
is taken instead of
> the
> the webservices.jar's QName.
>
> Regards Andreas
> -
Jar file containing FormInstanceBase
I am trying to initiate a process instance programatically using the approach described in section 5 of "Developing Custom Applications for LiveCycle Workflow". I am able to obtain a TaskManager object, but when I try to use its methods I get the error:
com.adobe.workflow.FormInstanceBase.class cannot be found.
According to the JavaDocs, there should be such a class, but I could find no such animal in adobe-wkf-client.jar. Am I missing a jar file? Which one?
Thanks.
Jared Langdonadobe-util.jar
Chris Trubiani
Adobe Systems -
Hello,
I'm developing a JSPDynpage with beans.
These beans connect to an R/3-system.
I want to make use of the Connector Framework.
I added the needed used DC's to my development component, but I'm still missing 1 jar-file with the IConnectorGateService-class (i think its the connectorserviceapi.jar) wich DC do I have to add to my used DC's?
Thanks for help,
Joachim
Message was edited by: Joachim Van PraetHello,
Ok, Then you have to create a seperate DC if type "<b>EXTERNAL Library</b>" , And then make it as a public part for use by other DC's. For more information you can try do like this.
<a href="https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2361">Add External Jar to DC</a>
I hope this will solve your problem.
Regards
Pravesh -
Imported par file to NWDS, jar file missing. Where find par file structure?
Hi All,
We want to implement idle session timeout on the portal. We found a wiki here on the subject. In order to implement the solution we need to make adjuestments to com.sap.portal.navigation.masthead.par.bak. When we import this par file to Netweaver Developer Studio, the libraries and jar files are missing. So obviously it errors then in portal as files are missing.
So I could add them manually but I don't know what the file structure is on this par file so don't where to add what. Does anyone know?
Also when I export the file after manually adding the missing files, will it export all the files or will it behave the same way as the import and leave out the additional files?
If anyone could help, I'd really appreciate it,
Kind regards,
Liz.Hi Bala,
I thought of that just before you responded and it worked!! Thanks for the response..
Regards,
Liz. -
Missing .jar files in the Weblogic Server 6.1 beta
The files /weblogic/lib/weblogic_sp.jar and /weblogic/lib/poolorb.jar are required
to be set in the
classpath, according to the documentation. But they are missing in the downloaded
version of the server.
Is there any solution?Hi Rajashree,
weblogic_sp.jar file is for service pack. I am assuming that you installed
latest version from the download site. the latest one is a bundled version
of wls6.0 with sp2. we put sp2 with 6.0 together, then you do not see that
jar file.
I am confused with poolorb.jar file. do you mean wlepool.jar and wleorb.jar?
those 2 files are used when you need to make a connection pool to WLE
server. if you do not use it, you do not need to include it in your
classpath.
Thanks
yu
Rajashree Desai <[email protected]> wrote in message
news:3b53ea0c$[email protected]..
>
The files /weblogic/lib/weblogic_sp.jar and /weblogic/lib/poolorb.jar arerequired
to be set in the
classpath, according to the documentation. But they are missing in thedownloaded
version of the server.
Is there any solution? -
"Java-Bean: True" missing after being packed in jar file
Hi All
X86, Windows XP Professional, J2SDK 1.4.2
I complied a section of code ", which is from << Thinking In Java>>(3rd).
Created a manifest file "BangBean.tmp"
<<
Name: bangbean/BangBean.class
Java-Bean: True
>>
And then packed class files into "BangBean.jar" with command
"jar cfm BangBean.jar Bang BangBean.tmp bangbean".
It's puzzling that "Java-Bean: Ture" was missing in the "BangBean.jar/META-INF/MENIFEST.MF" .
<<
Manifest-Version: 1.0
Created-By: 1.4.2 (Sun Microsystems Inc.)
Name: bangbean/BangBean.class
>>
What's more, after altering the"BangBean.tmp" into this
<<
Java-Bean: True
Name: bangbean/BangBean.class
>>
and had a another try.
I got a jar file with such MENIFEST.MF.
<<
Manifest-Version: 1.0
Created-By: 1.4.2 (Sun Microsystems Inc.)
Java-Bean: True
Name: bangbean/BangBean.class
>>
This jar file worked well in BDK's beanbox.
I've test it with JSDK 1.5.0, the same thing happened.
And I didn't encounter such problem in other bean programs.
I've searched " 'Java-Bean: True' missing " with google, but didn't get proper answers.
Is there anybody who can give a prompt about why this happend?
Thanks a lot for your help!
code
//: bangbean:BangBean.java
// A graphical Bean.
package bangbean;
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
import java.io.*;
import java.util.*;
import com.bruceeckel.swing.*;
public class
BangBean extends JPanel implements Serializable {
private int xm, ym;
private int cSize = 20; // Circle size
private String text = "Bang!";
private int fontSize = 48;
private Color tColor = Color.RED;
private ActionListener actionListener;
public BangBean() {
addMouseListener(new ML());
addMouseMotionListener(new MML());
public int getCircleSize() { return cSize; }
public void setCircleSize(int newSize) {
cSize = newSize;
public String getBangText() { return text; }
public void setBangText(String newText) {
text = newText;
public int getFontSize() { return fontSize; }
public void setFontSize(int newSize) {
fontSize = newSize;
public Color getTextColor() { return tColor; }
public void setTextColor(Color newColor) {
tColor = newColor;
public void paintComponent(Graphics g) {
super.paintComponent(g);
g.setColor(Color.BLACK);
g.drawOval(xm - cSize/2, ym - cSize/2, cSize, cSize);
// This is a unicast listener, which is
// the simplest form of listener management:
public void addActionListener(ActionListener l)
throws TooManyListenersException {
if(actionListener != null)
throw new TooManyListenersException();
actionListener = l;
public void removeActionListener(ActionListener l) {
actionListener = null;
class ML extends MouseAdapter {
public void mousePressed(MouseEvent e) {
Graphics g = getGraphics();
g.setColor(tColor);
g.setFont(
new Font("TimesRoman", Font.BOLD, fontSize));
int width = g.getFontMetrics().stringWidth(text);
g.drawString(text, (getSize().width - width) /2,
getSize().height/2);
g.dispose();
// Call the listener's method:
if(actionListener != null)
actionListener.actionPerformed(
new ActionEvent(BangBean.this,
ActionEvent.ACTION_PERFORMED, null));
class MML extends MouseMotionAdapter {
public void mouseMoved(MouseEvent e) {
xm = e.getX();
ym = e.getY();
repaint();
public Dimension getPreferredSize() {
return new Dimension(200, 200);
} ///:~
************************************************Since you didn't use code-formatting tags ([ code ] and [ /code ] without the spaces) it's kinda hard to look at it. But I'm sure it DID execute much more than just the return statement - maybe you're not closing a file or db connection, or maybe you're seeing a cached page, so it actually isn't executing ANYTHING on the server (is your browser set to never check for newer pages so it (almost) always returns from cache, for example?)
Maybe you are looking for
-
Need help with Java Script to perform a calculation in Adobe Acrobat Pro 9 form
I have a form (test) that I am creating in Adobe Acrobat Pro 9. I need help creating custom Java Script so I can get the desired answer. 1) There are several questions in each group that require a numerical answer between 0-4 2) There is a total fiel
-
Link to HTMLResources file in different folio
I was wondering if it is at all possible to link to a PDF file located in the HTMLResources folder of another folio (in a multi-issue app)?
-
On a Windows 7 Pro SP1 Toshiba Satellite A505 64bit laptop, when I run Itunes, no windows ever appears. If I watch Task Manager, "itunes.exe *32" appears briefly then disappears. I ended ipodservice.exe, no diff. Started Itunes in Itunes safemode, no
-
Get songs from ipod onto computer
their are certain songs that i dont have on my new computer but i have them on my ipod how do i get them onto my new cpu
-
hey everyone, can somebody tell me what wrong with my iphone 3G, b/c i just cannot update it to firmware 4.0. I have 3.1.2 right now and want to update to 4.0 but it keep said "This device isn't eligible for the requested build"