Win a copy of Fixing your Scrum this week in the Agile forum!

Richard Mendoza

Ranch Hand
+ Follow
since Feb 26, 2003
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Richard Mendoza

Can somebody explain to me these?

A client can pass a local home object reference to another application through its local interface. A local home object reference cannot be passed as an argument or result of a method on an enterprise bean�s remote home or remote interface.

Why is it that a client can pass a local home object reference to another application and in contrary it cannot be passed as an argument or result of a method of an EJB?
Hi Marc,

To complete the path here it is,

For Example1.java, it's located in
C:\MyProjects\SamplePrg\com\example\web\Example1.java

For Example2.java, it's located in
C:\MyProjects\SamplePrg\com\example\model\Example2.java

As you notice, Example1 is in ..\web package and Example2 is in ..\model package.

Compiling Example1.java is no problem...

But compiling Example2.java is what I get an error.. Because it makes use of Example1's instance so I use the import...

I tried what you did in your sample post.. And it did remove the error specifically for package in ..\web but I now get "package does not exist" for other packages like java.util, javax.servlet, etc..
15 years ago
Hi Marc,

To complete the path here it is,

For Example1.java, it's located in
C:\MyProjects\SamplePrg\com\example\web\Example1.java

For Example2.java, it's located in
C:\MyProjects\SamplePrg\com\example\model\Example2.java

As you notice, Example1 is in ..\web package and Example2 is in ..\model package.

Compiling Example1.java is no problem...

But compiling Example2.java is what I get an error.. Because it makes use of Example1's instance so I use the import...

I tried what you did in your sample post.. And it did remove the error specifically for package in ..\web but I now get "package does not exist" for other packages like java.util, javax.servlet, etc..
15 years ago
Hi,

This is related to my previous post above. I forgot to mention the error I was getting. I am getting an error of "package does not exist".
15 years ago
Hi,

I have created two different package.

1. com -> example -> web, which contains Example1.java

2. com -> example -> model, which contains Example2.java that makes use of Example1.java therefore has an import com.example.web.Example1 on the first line.

In compiling Example1.java, I just go to the subdirectory com\example\web and issue javac Example1.java. And it worked fine.

In compiling Example2.java, I just go to subdirectory com\example\model and issue javac Example2.java. And there goes the error.

How do I compile this without using special IDE but rather compiling only by hand?

Thanks!
15 years ago
Hi,

I have an sql that retrieves data from three different tables. One parent table and 2 children tables. One record in the parent may have many records in the children. The result set has six columns (Id, Date, BeginTime, EndTime, Location). The query was sorted by the primary key of the parent table and I need it that way, I need to group all same records. Eventually I stored the resultset in a List. How do I sort the contents of the list by date, begin time and end time?
15 years ago
TLD
I'm using an eclipse editor and I'm getting this error.

"The markup declarations contained or pointed to by the document type declaration must be well-formed."

The header for the tld file is:

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE taglib PUBLIC
"-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
"http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_2.dtd">

How do I fix this?
Hi Stefan Evans,

That really helps me a lot! Thanks for help!
15 years ago
JSP
Hi,

Is it possible to pass an array object in URL? something like..

var emp = new Array();

emp[0] = "Emp1";
emp[1] = "Emp1";
emp[2] = "Emp1";
emp[3] = "Emp1";

then pass using

http://localhost:8080/servlet/MyServlet?empArray=emp;

then in jsp,

request.getParameterValues("emp");

Please advise.
15 years ago
JSP
Would there be performance issue if say, there are more than a hundred objects added in an ArrayList?
15 years ago
Hi,

After study of the == operator I thought I already know how it behaves until I encountered this question.

if("String".substring(0) == "String")
System.out.println("Equal");
else
System.out.println("Not Equal");

Why does this piece of code prints "Equal"?
Hi,

I know that Exception is a checked exception.

My question is when I try this code:

import java.io.*;

public class AQuestion2{
public static void main(String args[]){
System.out.println("Before Try");
try{}
catch(IOException e){
System.out.println("Inside Catch");
}
System.out.println("At the End");
} // end of main
}//end of class

It doesn't compile.

But say we change the catch argument to "Exception", it compiles fine and produces an output.
Isn't that "Exception" is also a checked exception and should not also compile?

What is something that I am missing here?

Thanks!
Hi,

I found this question from Marcus Mock Exam #3:

Question 8)
Which of the following are valid statements

1) public class MyCalc extends Math
2) Math.max(s);
3) Math.round(9.99,1);
4)Math.mod(4,10);

Answer to Question 8)
Objective 9.1)
None of these are valid statements. The Math class is final and cannot be extended. The max method takes two parameters, round only takes one parameter and there is no mod parameter. You may get questions in the exam that have no apparently correct answer. If you are absolutely sure this is the case, do not check any of the options.

***Is this possible on the actual exam?
Hi,

public class ShiftOp{
public static void main(String[] args){
System.out.println(-6 >> -1);
System.out.println(-6 >> -2);
System.out.println(-6 >> -3);
System.out.println(-6 >> -4);
System.out.println(-6 >> -5);
}
}

The output for this program are all -1.

How do we do this using the short-cut formula?

Does anyone know the short-cut formula here?
Here is the question i got from Marcus:

Question 8)
Which of the following are valid statements

1) public class MyCalc extends Math
2) Math.max(s);
3) Math.round(9.99,1);
4)Math.mod(4,10);

Answer to Question 8)
Objective 9.1)
None of these are valid statements. The Math class is final and cannot be extended. The max method takes two parameters, round only takes one parameter and there is no mod parameter. You may get questions in the exam that have no apparently correct answer. If you are absolutely sure this is the case, do not check any of the options.

***Is this possible on the actual exam?