Im trying to create an instance: java.awt.geom.Point2D.Double in ColdFusion.
Point2D.Double is a nested class inside the abstract Point2D class. I tried to instantiate the class using:
<cfset PointClass = createObject("java", "java.awt.geom.Point2D.Double")>
This fails because ColdFusion cannot find the class.
And <cfset PointClass = createObject("java", "java.awt.geom.Point2D")>that does not work, because Point2D is an abstract class, and there is no public constructor that you can invoke on PointClass.init(x,y).
Right now, I resorted to creating my own Point class, which wraps the Point2D.Double class so that I can create an instance in ColdFusion. I don't think this is perfect, and I'm looking for ideas on how to directly create the Point2D.Double class in ColdFusion.
I also use ColdFusion 8.
source
share