Setting an IlpGeographicPositionConverter via CSS

Article ID: 2159
Last updated: 30 May, 2018
Article ID: 2159
Last updated: 30 May, 2018
Revision: 3
Views: 600
Posted: 19 Aug, 2004
by Dean J.
Updated: 30 May, 2018
by Gargani A.

Question

How can I set an IlpGeographicPositionConverter via CSS?

Answer

This sample shows how to specify an IlpGeographicPositionConverter via CSS.

If you try to specify the distribution's IlpGeographicPositionConverter in CSS as follows:

Positioning {

positionClass: "ilog.cpl.network.IlpGeographicPosition";

positionConverterClass: "ilog.cpl.network.IlpGeographicPositionConverter";

converterClass: "ilog.cpl.network.IlpGeographicPositionConverter";

}

you will get a java.lang.InstantiationException. This is because the IlpGeographicPositionConverter does not provide a

no-argument constructor.

To specify an IlpGeographicPositionConverter via CSS, you need to make it a JavaBeans by adding the no-argument constructor, so that the CSS engine can properly instantiate it at runtime.

The attached sample shows how to define such JavaBean implementation so that the IlpGeographicPositionConverter subtype can be used in the CSS and is properly configured.

Download attached Sample.zip file

This article was:   Helpful | Not helpful
Report an issue
Article ID: 2159
Last updated: 30 May, 2018
Revision: 3
Views: 600
Posted: 19 Aug, 2004 by Dean J.
Updated: 30 May, 2018 by Gargani A.
Attached files

Also listed in


Others in this category