ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wohlgemuth <>
Subject weird problem with Class instanceOf
Date Wed, 09 Aug 2006 01:50:22 GMT

at first I work since a long time with ant and wrote arround 50 ant
tasks sofar, I thought I know what I do...
...I was wrong

anyway thats my problem:

I have 3 classes

1. ClusterInitialzieTask, parent class:Task

-> used to intialize a cluster and contains objects of type 2. or 3.

2. ClusterParameter, parent class: ProjectComponent

-> a configuration parameter

3. Configuration, parent class: DataType

-> my configuration containing objects of type 2.

now I want to access the object configuration over a refrence

<config id="conf">
 <parameter name="username" value="my name" />

<initialize factory="tada">
 <config refid="conf"/>

and always get:

conf doesn't denote a config
	at edu.ucdavis.genomics.metabolomics.binbase.cluster.ant.Configuration.getContent(
	at edu.ucdavis.genomics.metabolomics.binbase.cluster.ant.ClusterInitializeTask.getProperties(

method where the call happens:

Object o = this.getCheckedRef(Configuration.class, "config");

when I access the refrence object direclty in the setRefId method and
make a simple System.err:

System.err.println(reference.getReferencedObject() instanceof


i become an output like this:

[initialize] false
[initialize] class

I know they are both from the same instance I just don't know why my
instanceof gives me a "false" and not a "true".

does anybody has an idea? I can also provide the sourcecode if requested.

thx for your help,


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message