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

30
LINES

< > BotCompany Repo | #1017050 // Multiple Thought Spaces Spike (dev.)

JavaX source code (desktop) [tags: use-pretranspiled] - run with: x30.jar

Download Jar. Uses 3874K of libraries. Click here for Pure Java version (7934L/55K).

1  
!7
2  
3  
sclass ThoughtSpaces {
4  
  new L<ThoughtSpace1> spaces;
5  
  new L<ThoughtSpace1> activeSpaces;
6  
  
7  
  void add(ThoughtSpace1 ts) {
8  
    spaces.add(ts);
9  
    activeSpaces.add(ts);
10  
  }
11  
  
12  
  bool think() {
13  
    ThoughtSpace1 ts = first(activeSpaces);
14  
    if (ts == null) false;
15  
    activeSpaces.remove(ts);
16  
    ts.think(true);
17  
    true;
18  
  }
19  
}
20  
21  
p-exp {
22  
  new ThoughtSpace1 ts;
23  
  ts.setInput("let's have a cup of Joe");
24  
  ts.add(Definition("let's have", "a grouping prefix"));
25  
  ts.addStepper(ts1_applyGroupingPrefix());
26  
  ts.lookingFor.add(ProposeRewrite);
27  
  new ThoughtSpaces spaces;
28  
  spaces.add(ts);
29  
  while (spaces.think());
30  
}

Author comment

Began life as a copy of #1017048

download  show line numbers  debug dex  old transpilations   

Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1017050
Snippet name: Multiple Thought Spaces Spike (dev.)
Eternal ID of this version: #1017050/4
Text MD5: 7a22b5f71455cca7f43ba8bdcb380903
Transpilation MD5: ba869fa5caf5c4a415d384286a34cc83
Author: stefan
Category: javax / a.i.
Type: JavaX source code (desktop)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-07-11 14:30:44
Source code size: 650 bytes / 30 lines
Pitched / IR pitched: No / No
Views / Downloads: 446 / 1029
Version history: 3 change(s)
Referenced in: [show references]