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

14
LINES

< > BotCompany Repo | #1001808 // runTranslator

JavaX fragment (include)

1  
  static S runTranslator(S text, S translatorID) {
2  
    Class javax = getJavaX();
3  
    File x = makeTempDir();
4  
    saveTextFile(new File(x, "main.java"), text);
5  
    new List<File> libraries_out;
6  
    
7  
    File y = cast call(javax, "applyTranslator", x, translatorID, "", libraries_out);
8  
    if (y == null) return null;
9  
    return loadTextFile(new File(y, "main.java"));
10  
  }
11  
  
12  
  static L<S> runTranslator(L<S> tok, S translatorID) {
13  
    ret javaTok(runTranslator(join(tok), translatorID));
14  
  }

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: #1001808
Snippet name: runTranslator
Eternal ID of this version: #1001808/1
Text MD5: 6f62a679f1576b1ae8f11391bb966319
Author: stefan
Category:
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2015-11-16 21:31:36
Source code size: 503 bytes / 14 lines
Pitched / IR pitched: No / Yes
Views / Downloads: 566 / 980
Referenced in: [show references]