Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  package org.drools.impl.adapters;
  
  import  org.kie.api.event.rule.ObjectDeletedEvent;
  import  org.kie.api.event.rule.ObjectInsertedEvent;
 import  org.kie.api.event.rule.ObjectUpdatedEvent;
 
 public class WorkingMemoryEventListenerAdapter implements org.kie.api.event.rule.RuleRuntimeEventListener {
 
     private final WorkingMemoryEventListener delegate;
 
         this. = delegate;
     }
 
     public void objectInserted(final ObjectInsertedEvent event) {
             public FactHandle getFactHandle() {
                 return new FactHandleAdapter(event.getFactHandle());
             }
 
             public Object getObject() {
                 return event.getObject();
             }
 
             public PropagationContext getPropagationContext() {
                 throw new UnsupportedOperationException("This operation is no longer supported");
             }
 
             public KnowledgeRuntime getKnowledgeRuntime() {
                 return new KnowledgeRuntimeAdapter((org.kie.internal.runtime.KnowledgeRuntime)event.getKieRuntime());
             }
         });
     }
 
     public void objectUpdated(final ObjectUpdatedEvent event) {
             @Override
             public FactHandle getFactHandle() {
                 return new FactHandleAdapter(event.getFactHandle());
             }
 
             @Override
             public Object getOldObject() {
                 return event.getOldObject();
             }
 
             @Override
             public Object getObject() {
                 return event.getObject();
             }
 
             @Override
             public PropagationContext getPropagationContext() {
                 throw new UnsupportedOperationException("This operation is no longer supported");
             }
 
             @Override
             public KnowledgeRuntime getKnowledgeRuntime() {
                 return new KnowledgeRuntimeAdapter((org.kie.internal.runtime.KnowledgeRuntime)event.getKieRuntime());
             }
         });
     }
 
     public void objectDeleted(final ObjectDeletedEvent event) {
         .objectRetracted(new ObjectRetractedEvent() {
             @Override
             public FactHandle getFactHandle() {
                 return new FactHandleAdapter(event.getFactHandle());
             }
 
             @Override
             public Object getOldObject() {
                 return event.getOldObject();
             }
 
             @Override
             public PropagationContext getPropagationContext() {
                 throw new UnsupportedOperationException("This operation is no longer supported");
 
             }
 
             @Override
             public KnowledgeRuntime getKnowledgeRuntime() {
                 return new KnowledgeRuntimeAdapter((org.kie.internal.runtime.KnowledgeRuntime)event.getKieRuntime());
             }
         });
     }
 
     @Override
     public int hashCode() {
         return .hashCode();
     }
 
     @Override
    public boolean equals(Object obj) {
    }
New to GrepCode? Check out our FAQ X