Viswa Repalle created JBRULES-3523:
--------------------------------------
Summary: java.lang.ClassCastException:
org.drools.facttemplates.FactTemplateObjectType cannot be cast to
org.drools.base.ClassObjectType
Key: JBRULES-3523
URL:
https://issues.jboss.org/browse/JBRULES-3523
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Reporter: Viswa Repalle
Assignee: Mark Proctor
I have analyzed the issue and found that the issue is happening at the initDeclaredMask
method of BetaNode.java of drools-core-5.4.0.final.jar at the following lines of code:
ObjectType objectType = pattern.getObjectType();
if ( !(objectType instanceof ClassObjectType) ) {
// InitialFact has no type declaration and cannot be property specific
// Only ClassObjectType can use property specific
rightDeclaredMask = Long.MAX_VALUE;
}
Class objectClass = ((ClassObjectType) objectType).getClassType();
The above code will throw ClassCastException as irrespective of the objectType is instance
of ClassObjectType or not, trying to type cast to ClassObjectType.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see:
http://www.atlassian.com/software/jira