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


< > BotCompany Repo | #1007324 // New hotwire using outer JavaX for clients (LIVE)

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

Libraryless. Click here for Pure Java version (3045L/18K).

// custom mainClass only works with hotwire_here
static Class<?> hotwire(S src, IF1<ClassLoader, S> calculateMainClass default lambda1 mainClassNameForClassLoader) {
  Class j = getJavaX();
  if (isAndroid()) {
    synchronized(j) { // hopefully this goes well...
      List<File> libraries = new ArrayList<File>();
      File srcDir = (File) call(j, "transpileMain", src, libraries);
      if (srcDir == null)
        fail("transpileMain returned null (src=" + quote(src) + ")");
      Object androidContext = get(j, "androidContext");
      return (Class) call(j, "loadx2android", srcDir, src);
  } else {
    ifdef hotwire_here
    ret hotwire_overInternalBot(src, calculateMainClass);
    ifndef hotwire_here
    Class c = cast call(j, "hotwire", src);
    ret c;

Author comment

Began life as a copy of #1000963

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1007324
Snippet name: New hotwire using outer JavaX for clients (LIVE)
Eternal ID of this version: #1007324/8
Text MD5: d05c219259365093b2253484029a0671
Transpilation MD5: 2736f0b100547b337d48aa1fd7489a80
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-06-05 01:24:05
Source code size: 886 bytes / 25 lines
Pitched / IR pitched: No / No
Views / Downloads: 715 / 1053
Version history: 7 change(s)
Referenced in: [show references]