I have been trying to create a custom chart. one of the main problem I am running into is defining the Plot !
I have a class object :
class LabTestChart():
instance = None
def __init__( self, chart ):
self.chart = chart
self.plotObj = chart.getPlot()
# Each sub-plot is of type org.jfree.chart.plot.XYPlot
# index 0 is the main part
self.subPlots = self.plotObj.getSubplots()
and it gives me an error as :
AttributeError: 'com.inductiveautomation.factorypmi.application.com' object has no attribute 'getSubplots'
at org.python.core.Py.AttributeError(Py.java:173)
at org.python.core.PyObject.noAttributeError(PyObject.java:930)
at org.python.core.PyObject.object___getattribute__(PyObject.java:3692)
at org.python.core.PyObject$object___getattribute___exposer.__call__(Unknown Source)
at org.python.core.Deriveds.__findattr_ex__(Deriveds.java:59)
at org.python.core.PyObjectDerived.__findattr_ex__(PyObjectDerived.java:983)
at org.python.core.PyObject.__getattr__(PyObject.java:923)
at org.python.pycode._pyx640.__init__$2(<module:shared.mixing.Reports.LabHistory>:55)
at org.python.pycode._pyx640.call_function(<module:shared.mixing.Reports.LabHistory>)
at org.python.core.PyTableCode.call(PyTableCode.java:165)
at org.python.core.PyBaseCode.call(PyBaseCode.java:301)
which is little weird as jfree chart has the Subplot object !
Thanks