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

39
LINES

< > BotCompany Repo | #1005042 // Name 2 Program [dev.]

JavaX source code - run with: x30.jar

1  
!752
2  
3  
concepts.
4  
5  
// A name defined by a string
6  
concept Name {
7  
  S name;
8  
  S saidByWhom;
9  
  long saidWhen;
10  
  
11  
  *() {}
12  
  *(S *name, S *saidByWhom, long *saidWhen) { change(); }
13  
}
14  
15  
// Convert a name to a snippet ID
16  
concept Name2Program extends IdentificationTask {
17  
  new Ref input;
18  
  S outSnippetID;
19  
  
20  
  *() {}
21  
  *(Concept input, S outSnippetID) {
22  
    this.input.set(input);
23  
    this.outSnippetID = outSnippetID;
24  
    change();
25  
  }
26  
}
27  
28  
// Let's validate stuff so it can be used.
29  
concept Validate {
30  
  new Ref object;
31  
  
32  
  *() {}
33  
  *(Concept object) {
34  
    this.object.set(object);
35  
  }
36  
}
37  
38  
p {
39  
}

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1005042
Snippet name: Name 2 Program [dev.]
Eternal ID of this version: #1005042/1
Text MD5: 62151a61b3491e935986ed7ebe51e340
Author: stefan
Category: javax
Type: JavaX source code
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-10-01 22:44:32
Source code size: 625 bytes / 39 lines
Pitched / IR pitched: No / No
Views / Downloads: 503 / 510
Referenced in: [show references]