I am trying to use the following like so.
property name=“calendar” inject=“javaloader:java.util.Calendar”;
The idea is that I can use this object to do some data conversion, the problem is that when I try to use it I am getting the below error. So the question is how can this work, I tried using
myCal = calendar.init();
But that gives an error saying it can’t find a constructor with init(‘’), but the javaDocs say there is a default constructor Calendar() so can anyone help in explaining what I am doing wrong here. As you can tell I don’t use JavaLoader much so I am not sure what is going wrong.
Application Execution Exception
Error Type: Object : [N/A]
Error Messages: Object instantiation exception.
An exception occurred while instantiating a Java object. The class must not be an interface or an abstract class. If the class has a constructor that accepts an argument, you must call the constructor explicitly using the init(args) method. Error : Class coldfusion.runtime.java.JavaProxy can not access a member of class java.util.Calendar with modifiers “protected”