It's a Java (using JUnit) enterprise Web application with no mock objects pre-built, and it would require a vast amount of time not estimated to create them. Is there a testing paradigm that would give me "some" test coverage, but not total coverage?
...
if something is not working properly.. or some plugins are loaded properly in my eclipse... i often get suggestion to open eclise in clean mode... so how to run in clean mode? and what happens if i do so?
...
Possible Duplicate: How to access java-classes in the default-package?
Is it possible to import a class in Java which is in the default package? If so, what is the syntax? For example, if you have
package foo.bar;
public class SomeClass {
// ...
in one file, you can write
package baz.fonz;
import foo.bar.SomeClass;
pu...
WebSphere logs the warning message “SRTServletRes W WARNING: Cannot set header. Response already committed” for one JSP request. I need the respone headers later in my code. I did some research and understood that Servlet is trying to send more data to the output stream, but the stream is already been committed. I did not understand wh...
How do you run multiple JVMs on a single machine? How do you call methods in a different JVM?
...
Hi everybody!
I am using Maven for my project and have following qustion:
I want to see the logging output of my JUnit tests (log4j, System.out, whatever) in tests reports. Do you have any idea how to achieve this?
Thanks ;-)
...
I am doing this in each and every DAL method:
public static Product GetProductByPartNumber(String partNumber)
{
Session session = HibernateUtil.getSessionFactory().getCurrentSession();
session.beginTransaction();
Product product = (Product)session.createCriteria(Product.class)
...
SOLVED! thanks to VonC
I am trying to get Eclipse Galileo to re-run on my computer - i have run it before with no problems but now i keep getting this error:
A java Runtime Environment (JRE) or Java Development kit (JDK) must be available in order to run Eclipse. No Java virtual machine was found after searching the following locat...
I solved my problem, but I just want to get a better understanding of how things are working.
I am looping through a collection, creating/initializing a new Product, adding a category it its collection (mapped m:m) and then saving and commiting the transaction.
for(Blah b : blahs)
{
session = getcurrensession();
Product p = new Pr...
Hello,
I'm interested in technologies(solutions) that permits Java and .NET interoperate. I have tried the following and it works but I would like to know if there are other solutions:
Sockets
Web Services (Metro)
CORBA (IIOP.NET)
Messaging (QPid)
IKVM
Does anyone know other technologies(solutions) that enable Java and .NET interope...
Im a PHP-programmer and wonder what this line means.
System.out.printf("exp(%.3f) is %.3f%n", x, Math.exp(x))
what does %.3f, %.3f%n and the comma x means?
...
For HTTP communications in Java, I normally use the HttpClient library. However, my latest project utilizes the Eclipse API. Are there features in the API that have the same capabilities as HttpClient?
As implied, this particular project requires me to use GET, PUT, and POST requests. I also need to post multipart MIMEs where the Con...
Hi,
I'm trying to load bean runtime configuration.
@Stateless
public class MyBean implements MyLocal{
@Resource String runtimeSetting1="default_value";
//....
}
I cannot find out how to create custom resource on app server side (Glassfish) - I have no idea what I should enter in "Factory Class" field.
Maybe there is a be...
i know about python, ruby, perl etc.. but is java a really open source programming language?
because i searched on google too but didnt get proper answer. so asking here
...
Using a msdos window i am piping in a amazon.txt file.
I am trying to use the collections framework. Keep in mind i want to keep this
as simple as possible.
What i want to do is count all the unique words in the file... no duplicates
This is what i have so far.. please be kind this is my first java project.
import java.util.Scanner;
im...
As Java is an open source: if we have developed good classes which may help anybody.. Can we add them to standard Java library? If yes: how?
...
Will java applications run on the nexus? I would want to run a particular java application.
...
I am attempting to Store() the change made to my application's Properties. The .Properties file is located in 'resources' package, which is different from the package that contains my UI and model.
I opened the package using:
this.getClass().getClassLoader().getResourceAsStream("resources/settings.properties")
Is there a functional e...
package timeToys;
import java.util.regex.Pattern;
**
* A DayTime is an immutable object that stores a moment of day represented in
* hour, minutes and seconds. Day or year are not defined.
*
* @author marius.costa <[email protected]>
*/
public class DayTime {`enter code here`
private int hour;// hour of the day
pr...
I have a Spring application (Spring version 2.5.6.SEC01, Spring Security version 2.0.5) with the following setup (this is based off of this question):
In the security-config.xml file, I have the following configuration:
<http>
<!-- Restrict URLs based on role -->
<intercept-url pattern="/WEB-INF/jsp/login.jsp*" access="ROLE_ANONYMO...