comp.lang.java.programmer
  Home FAQ Contact Sign in
comp.lang.java.programmer only
 
Advanced search
July 2008
motuwethfrsasuw
 123456 27
78910111213 28
14151617181920 29
21222324252627 30
28293031    31
2008
 Jan   Feb   Mar   Apr 
 May   Jun   Jul   Aug 
 Sep   Oct   Nov   Dec 
2008 2007 2006  
total
comp.lang.java.programmer Profile…
RELATED GROUPS

POPULAR GROUPS

more...

 Up
  Some questions about ThreadLocal         


Author: lightning
Date: Jul 31, 2008 22:44

In javadoc:
Each thread holds an implicit reference to its copy of a thread-local
variable as long as the thread is alive and the ThreadLocal instance
is accessible; after a thread goes away, all of its copies of thread-
local instances are subject to garbage collection (unless other
references to these copies exist).

It seems only when thread "goes away",the threadlocals of that thread
will be cleaned.
But what about when using threadpools?
For example:
Executors.newFixedThreadPool()

In TOMCAT,the threadlocals works fine because framework such dwr ,
struts2 or spring transactionmanager using threadlocals to store many
things.How did it work?
Will it work fine no matter no matter Tomcat is using threadpool or
using singlethread mode?
3 Comments
  Control break pattern         


Author: Roedy Green
Date: Jul 31, 2008 20:05

Are there any classes or special techniques for handling a problem
like this?

You have a list sorted by some category. You want to do something
special prior to processes sing the first of a string of dups and
something special after.

It is sort of like a Visitor pattern except you want a start Group and
end Group method invoked as well as an item processor.

Then there is the generalisation, the control break where you have
several levels of keys.
--

Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com
14 Comments
  computer,language,java,,__--programmer...         


Author: REVANTH
Date: Jul 31, 2008 18:10

1 Comment
  computer,language,java,,__--programmer...         


Author: REVANTH
Date: Jul 31, 2008 18:09

no comments
  Question on Java .form and Eclipse         


Author: Hongyu
Date: Jul 31, 2008 11:30

Hi,

Sorry for asking such simple questions first, but I can't find it from
the Internet, and I am a newbie to Java and Eclipse and don't have
someone to ask around.

I got a zipped java source code, after unzipping, it contains
some .java, .jar, and .form files. I have asked how to import them
into Eclipse in this forum before. Here I have a new question:

The .form files are created by which software, and how can it open in
Eclipse? I knew that in Visual Basic one can create .form by dragging
and dropping different components suach as buttons. I would guess that
this java .form is simiar to that VB .form. I checked from Internet
that it seems there is one like JFormDesigner for java, but i also saw
that it creates .jfd file rather than .form file. When I open the
java .form in the Eclipse, I saw some xml code. The .java code
contains "import javax.swing.*;", so I would assume those .form is
also from java swing, but how it is obtained and how it can open/edit
like figure form in Eclipse? Can someone kindly help me?

Thanks a lot for the help in advance.

Hongyu
14 Comments
  Connecting Via HTTPS         


Author: HugeBob
Date: Jul 31, 2008 11:12

Hi All,

I'm trying to import the public key of a secure site (https). But, I'm
having a lot of difficulty getting this to work. The JRE is on a Unix
box (SunOS 5.10). From my Windows XP workstation, I went to the site
with IE and retrieved the public key in DER Binary Format and saved it
to a *.cer file on the Unix box (via Samba share). I then used the
keytool to import it into the keystore at /{jrun_root}/jre/lib/
security/cacerts. I verified that it was in there with the keytool -
list -keystore cacerts command. Here's the code I'm trying to run.
But, I get a java.net.ssl.SSLHandshakeException. Can anyone lend some
guidance here?

import java.net.*;
import java.io.*;
import java.util.*;
import java.net.ssl.*;

public class WebService {

public static String sessionCookie;
Show full article (2.28Kb)
1 Comment
  Java generics "registry" design pattern         


Author: laviofer
Date: Jul 31, 2008 10:37

So here is what I am after:

I want to have a generic class MyClass that holds a data member
ArrayList m_TList

Now, suppose I have a method that reads a file, and has to fill in the
list. The file is a list of strings, and I want to have a registry
class that knows how to turn a string into a T object. T is
"Identifiable" - that is, each object has a unique String ID. I want
the T class to be able to return its (static) Registry object so to
have something like:
Show full article (0.90Kb)
no comments
  Re: Language about Java         


Author: Andrew Thompson
Date: Jul 31, 2008 09:49

On Aug 1, 2:40=A0am, Gani gmail.com> wrote:
> Free ..

=2E.ly assassinated ..
>..Java Book Architect..

=2E.From a prodigious bishop.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"If he's -- the inference is that somehow he thinks slavery
is a
-- is a noble institution I would -- I would strongly
reject that assumption -- that John Ashcroft is a open-minded,
inclusive person."

--- Adolph Bush,
NBC Nightly News With Tom Brokaw, Jan. 14, 2001
no comments
  Re: Finding simple Java class for implementation of text recognition         


Author: Andrew Thompson
Date: Jul 31, 2008 09:45

On Jul 31, 10:45=A0pm, cumlibrisnonso...@gmail.com wrote:

Sub:
Finding worthy Java amount for screwdriver of bell royalty

Well, the whole 'agreeable' reflector can be covered by hiring
a writer to do it for you. Beyond that, you might
need to ponder some finance.
> Hello you all.

G'Day!
> I am in a hobby project and would need a easy-to-use Java class or
> component I can use more or less out of the box ..

Your device for this 'box' is ..what?
>...in my project for
> simple text recognition.

Define 'territorial salad guidance' for me.
>...I want to attend one or more pieces of champagne
> with one or more pieces of text to get some sort of indication if (1)
> the information is auto-generated and (2) the writer is the same
> person.
Show full article (1.97Kb)
no comments
  Apache Tomcat 6.0.18         


Author: Roedy Green
Date: Jul 31, 2008 09:21

Apache Tomcat 6.0.18 came out yesterday. I could not find the
release notes to see what they changed that would have any impact on
writing Java code.
--

Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com
3 Comments
1 2 3 4 5 6 7 8 9