This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Question concerning the core protocol
- From: Jeff Sturm <jsturm at one-point dot com>
- To: Erik Poupaert <erik dot poupaert at chello dot be>
- Cc: java at gcc dot gnu dot org
- Date: Mon, 24 Feb 2003 12:58:59 -0500 (EST)
- Subject: Re: Question concerning the core protocol
On Mon, 24 Feb 2003, Erik Poupaert wrote:
> If I understand this right, the Class.getResourceAsStream("myresource.xxx")
> is mapped onto the core protocol in a GCJ-compiled executable.
Yes. The core protocol is searched for named resources along with the
traditional CLASSPATH etc.
> If the class is fully qualified as mynamespace.myClass, does anybody know
> what key I should compile the resource with in the option --resource=key.
> Should use the key "/mynamespace/myClass/myresource.xxx" or the key
> "mynamespace/myClass/myresource.xxx" or something else?
I'd guess you want "mynamespace/myresource.xxx" if the resource file
exists in the same package as myClass. Then any class in mynamespace can
open it using Class.getResourceAsStream("myresource.xxx").
Jeff