Hi again, thanks for the hints.
I have installed Java 8 but the output is essentially the same. There
is a log attached with a very simple example.
I will keep investigating this. Regards,
Luís
On 25 August 2014 18:16, Mark Coletti <[log in to unmask]> wrote:
> First, as Sean suggested, ensure you're using the SVN version of GeoMASON.
> Failing that, use the verbose setting for the class loader to doubly make
> sure that the proper class is being loaded, and not an old version lingering
> in your class path. Also, sometimes Eclipse and Netbeans squirrel away
> cached versions of class files and tend to fanatically cling to them even
> when newer versions are present.
>
> Cheers!
>
> Mark
>
>
> On Sun, Aug 24, 2014 at 1:54 PM, Luís de Sousa <[log in to unmask]>
> wrote:
>>
>> Hi Sean,
>>
>> Compiling in the command results in a different output, but still the
>> removeGeometry method is raising an error:
>>
>> BasicSim.java:49: error: cannot find symbol
>> spaceWanderer.removeGeometry(anim);
>> ^
>> symbol: method removeGeometry(MasonGeometry)
>> location: variable spaceWanderer of type GeomVectorField
>> 1 error
>>
>> I am using OpenJDK on this system; will give a try with Oracle 8 and
>> report back.
>>
>> Thank you,
>>
>> Luís
>>
>> On 23 August 2014 20:09, Sean Luke <[log in to unmask]> wrote:
>> > I got no idea. The SVN repository version of GeoMASON (which I checked)
>> > has both of these methods. What if you build without Eclipse, but just
>> > using javac?
>> >
>> > Sean
>> >
>> > On Aug 23, 2014, at 1:57 PM, Luís de Sousa <[log in to unmask]>
>> > wrote:
>> >
>> >> Dear all,
>> >>
>> >> I am trying to run some of my sample models against MASON 18. I am
>> >> doing it on a fresh system with Eclipse Kepler and referencing the
>> >> jars for MASON/GeoMASON/JTS.
>> >>
>> >> Classes reliant solely on MASON are compiling, but there are two
>> >> methods in GeoMASON classes that are not being found. The error
>> >> messages:
>> >>
>> >> "The method removeGeometry(MasonGeometry) is undefined for the type
>> >> GeomVectorField"
>> >>
>> >> "The method updateSpatialIndex() is undefined for the type
>> >> GeomVectorField"
>> >>
>> >> I have tried to compile these models against the GeoMASON 1.4 and 1.1
>> >> jars, but I always get the same errors. On the development environment
>> >> I reference the source code and all goes well.
>> >>
>> >> Any hints on what may be causing this?
>> >>
>> >> Thank you,
>> >>
>> >> Luís
>
>
>
>
> --
> [log in to unmask]
>
$ java -version
java version "1.8.0_20"
Java(TM) SE Runtime Environment (build 1.8.0_20-b26)
Java HotSpot(TM) Client VM (build 25.20-b23, mixed mode)
$ javac -version
javac 1.8.0_20
$ ls -la
total 2348
drwxrwxr-x 2 user user 4096 Aug 25 19:08 .
drwxr-xr-x 9 user user 4096 Aug 25 18:57 ..
-rw------- 1 user user 45876 Aug 23 19:22 geomason.1.5.jar
-rw-rw-r-- 1 user user 334 Aug 25 19:07 Hello.java
-rw------- 1 user user 760315 Aug 23 19:22 jts-1.13.jar
-rw------- 1 user user 1577781 Aug 23 18:43 mason.18.jar
$ cat Hello.java
import sim.util.geo.MasonGeometry;
import sim.field.geo.GeomVectorField;
public class Hello
{
public static void main(String[] args)
{
System.out.println("Hello there!");
GeomVectorField geomField = new GeomVectorField(10, 10);
MasonGeometry geom = new MasonGeometry();
geomField.removeGeometry(geom);
}
}
$ javac -cp mason.18.jar:geomason.1.5.jar:jts-1.13 Hello.java
Hello.java:12: error: cannot find symbol
geomField.removeGeometry(geom);
^
symbol: method removeGeometry(MasonGeometry)
location: variable geomField of type GeomVectorField
1 error
|