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

9
LINES

< > BotCompany Repo | #1001204 - findMainClass

JavaX fragment (include)

// returns actual CNC
static L<S> findMainClass(L<S> tok) {
  for (L<S> c : reversedList(allClasses(tok))) {
    S name = getClassDeclarationName(c);
    if (eq(name, "main") || name.startsWith("x"))
      return c;
  }
  ret findBlock("m {", tok);
}

download  show line numbers  debug dex   

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

No comments. add comment

Snippet ID: #1001204
Snippet name: findMainClass
Eternal ID of this version: #1001204/1
Text MD5: c97e76fe01e6c53ec7c85f61e548c384
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-07-30 17:44:22
Source code size: 258 bytes / 9 lines
Pitched / IR pitched: No / No
Views / Downloads: 400 / 1703
Referenced in: [show references]

Formerly at http://tinybrain.de/1001204 & http://1001204.tinybrain.de