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

18
LINES

< > BotCompany Repo | #1025222 // tok_fieldAccessProxy [dev.]

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (3986L/26K).

1  
svoid tok_fieldAccessProxy(LS tok) {
2  
  int i;
3  
  while ((i = jfind(tok, "fieldAccessProxy <id> for virtual <id> {")) >= 0) {
4  
    tok.set(i, "class");
5  
    S proxyName = tok.get(i+2), vtype = tok.get(i+8);
6  
    int iOpening = indexOf(tok, i, "{");
7  
    int iClosing = tok_findEndOfBlock(tok, iOpening)-1;
8  
    LLS decls = splitAtListElement_multi(subList(tok, iOpening+1, iClosing), ";");
9  
    new StringBuilder buf;
10  
    for (LS tokD : decls) {
11  
      if (l(tokD) < 3) continue;
12  
      //if (eq(second(tokD), "import"))
13  
    }
14  
    replaceTokens(tok, i+4, iClosing-1, str(buf));
15  
    reTok(tok, i, iClosing);
16  
    pnlStruct(decls);
17  
  }
18  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1025222
Snippet name: tok_fieldAccessProxy [dev.]
Eternal ID of this version: #1025222/5
Text MD5: ea957c624f5a38954dde0abb52513de9
Transpilation MD5: c2ae5d2078172daa54b0b1d1824301fe
Author: stefan
Category: javax / transpiling
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-09-13 17:58:15
Source code size: 641 bytes / 18 lines
Pitched / IR pitched: No / No
Views / Downloads: 231 / 321
Version history: 4 change(s)
Referenced in: [show references]