Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

24
LINES

< > TinyBrain | #1008910 - CtxContext - context for evaluating ctx conditions

JavaX fragment (include)

1  
sclass CtxContext {
2  
  // general for bot
3  
  SS regexpMacros, globals;
4  
5  
  // per session
6  
  S activeRule, activeAnalyzer;
7  
  SS vars = new HashMap;
8  
  
9  
  S input;
10  
  new StringBuilder newOutput;
11  
  
12  
  int conversationLength;
13  
  bool jumpaway, thinkagain;
14  
  S nextRule;
15  
  int safetyCounter; // number of rules applied in step
16  
  new L<S> rulesFired;
17  
  new L<S> urlsToOpen;
18  
  new L<S> matches; // MATCH1...
19  
  
20  
  void setActiveRule(S rule) {
21  
    activeRule = rule;
22  
    print("New active rule: " + rule);
23  
  }
24  
}

download  show line numbers  debug dex   

Travelled to 10 computer(s): aoiabmzegqzx, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, onxytkatvevr, tslmcundralx, tvejysmllsmz

No comments. add comment

Snippet ID: #1008910
Snippet name: CtxContext - context for evaluating ctx conditions
Eternal ID of this version: #1008910/23
Text MD5: 0eeb80c7ff1e3b11e96e9e0e6dc50a19
Author: stefan
Category: javax / a.i.
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-07-04 18:10:46
Source code size: 520 bytes / 24 lines
Pitched / IR pitched: No / No
Views / Downloads: 171 / 563
Version history: 22 change(s)
Referenced in: [show]