public LogicalRetractCallback(MarshallerReaderContext context) throws IOException { this.tms = context.wm.getTruthMaintenanceSystem(); this.handle = context.handles.get( context.readInt() ); this.context = context.propagationContexts.get( context.readLong() ); this.activation = (Activation) context.terminalTupleMap.get( context.readInt() ).getObject(); this.beliefSet = (BeliefSet) this.tms.getJustifiedMap().get( handle.getId() ); for ( LinkedListEntry entry = (LinkedListEntry) beliefSet.getFirst(); entry != null; entry = (LinkedListEntry) entry.getNext() ) { final LogicalDependency node = (LogicalDependency) entry.getObject(); if ( node.getJustifier() == this.activation ) { this.node = node; break; } } }
long startTime = inCtx.readLong(); long endTime = inCtx.readLong(); trigger.setEndTime( new Date( endTime ) ); trigger.setCronExpression( expr ); if (inCtx.readBoolean()) { long nextFireTime = inCtx.readLong(); trigger.setNextFireTime( new Date( nextFireTime ) ); long startTime = inCtx.readLong(); trigger.setStartTime( new Date( startTime ) ); if (inCtx.readBoolean()) { long endTime = inCtx.readLong(); trigger.setEndTime( new Date( endTime ) ); trigger.setRepeatCount( repeatCount ); if (inCtx.readBoolean()) { long nextFireTime = inCtx.readLong(); trigger.setNextFireTime( new Date( nextFireTime ) ); long period = inCtx.readLong(); trigger.setPeriod( period ); String[] calendarNames = (String[]) inCtx.readObject(); long startTime = inCtx.readLong();
int type = context.stream.readInt(); int id = context.stream.readInt(); long recency = context.stream.readLong(); long activationsCount = 0; if (type == 2) { startTimeStamp = context.stream.readLong(); duration = context.stream.readLong(); expired = context.stream.readBoolean(); activationsCount = context.stream.readLong();
public void read(MarshallerReaderContext inCtx) throws IOException, ClassNotFoundException { InternalFactHandle factHandle = inCtx.handles.get( inCtx.readInt() ); String entryPointId = inCtx.readUTF(); EntryPointNode epn = ((ReteooRuleBase) inCtx.wm.getRuleBase()).getRete().getEntryPointNode( new EntryPoint( entryPointId ) ); String className = inCtx.readUTF(); Class< ? > cls = ((ReteooRuleBase) inCtx.wm.getRuleBase()).getRootClassLoader().loadClass( className ); ObjectTypeNode otn = epn.getObjectTypeNodes().get( new ClassObjectType( cls ) ); long nextTimeStamp = inCtx.readLong(); TimerService clock = inCtx.wm.getTimerService(); JobContext jobctx = new ExpireJobContext( new WorkingMemoryReteExpireAction( factHandle, otn ), inCtx.wm ); JobHandle handle = clock.scheduleJob( job, jobctx, new PointInTimeTrigger( nextTimeStamp, null, null ) ); jobctx.setJobHandle( handle ); }