/**
  * Construct given a semantic <code>ObjectType</code> and the provided unique id. All <code>
  * ObjectTypdeNode</code> have node memory.
  *
  * @param id The unique id for the node.
  * @param objectType The semantic object-type differentiator.
  */
 public ObjectTypeNode(
     final int id,
     final EntryPointNode source,
     final ObjectType objectType,
     final BuildContext context) {
   super(
       id,
       context.getPartitionId(),
       context.getRuleBase().getConfiguration().isMultithreadEvaluation(),
       source,
       context.getRuleBase().getConfiguration().getAlphaNodeHashingThreshold());
   this.objectType = objectType;
   setObjectMemoryEnabled(context.isObjectTypeNodeMemoryEnabled());
 }
Example #2
0
  /**
   * Construct given a semantic <code>ObjectType</code> and the provided unique id. All <code>
   * ObjectTypdeNode</code> have node memory.
   *
   * @param id The unique id for the node.
   * @param objectType The semantic object-type differentiator.
   */
  public ObjectTypeNode(
      final int id,
      final EntryPointNode source,
      final ObjectType objectType,
      final BuildContext context) {
    super(
        id,
        context.getPartitionId(),
        context.getRuleBase().getConfiguration().isMultithreadEvaluation(),
        source,
        context.getRuleBase().getConfiguration().getAlphaNodeHashingThreshold());
    this.objectType = objectType;
    this.lrUnlinkingEnabled = context.getRuleBase().getConfiguration().isLRUnlinkingEnabled();
    setObjectMemoryEnabled(context.isObjectTypeNodeMemoryEnabled());

    if (ClassObjectType.DroolsQuery_ObjectType.isAssignableFrom(objectType)) {
      queryNode = true;
    }
  }