예제 #1
0
  void ICmd$$FUNCTIONS() {
    Proto.Fxn fxn;

    // fxn ICmd.main
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ICmd$$main",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ICmd.Module", "xdc.tools"), null, 0, -1, false));
    // fxn ICmd.exec
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ICmd$$exec",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ICmd.Module", "xdc.tools"), null, 0, -1, false));
    // fxn ICmd.run
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ICmd$$run",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ICmd.Instance", "xdc.tools"), $$T_Obj, 2, 2, false));
    fxn.addArg(0, "cmdr", (Proto) om.findStrict("xdc.tools.Cmdr.Instance", "xdc.tools"), $$UNDEF);
    fxn.addArg(1, "args", new Proto.Arr($$T_Str, false), $$DEFAULT);
  }
예제 #2
0
  void ResourceBundle$$FUNCTIONS() {
    Proto.Fxn fxn;

    // fxn ResourceBundle.getResourceBundle
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ResourceBundle$$getResourceBundle",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ResourceBundle.Module", "xdc.tools"),
                    (Proto) om.findStrict("xdc.tools.ResourceBundle.Instance", "xdc.tools"),
                    2,
                    2,
                    false));
    fxn.addArg(0, "pkgName", $$T_Str, $$UNDEF);
    fxn.addArg(1, "lang", $$T_Str, $$UNDEF);
    // fxn ResourceBundle.getString
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ResourceBundle$$getString",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ResourceBundle.Instance", "xdc.tools"),
                    $$T_Str,
                    1,
                    1,
                    false));
    fxn.addArg(0, "key", $$T_Str, $$UNDEF);
    // fxn ResourceBundle.formatMessage
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ResourceBundle$$formatMessage",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ResourceBundle.Instance", "xdc.tools"),
                    $$T_Str,
                    2,
                    2,
                    false));
    fxn.addArg(0, "key", $$T_Str, $$UNDEF);
    fxn.addArg(1, "args", $$T_Obj, $$UNDEF);
  }
예제 #3
0
  void SunSparc7$$CREATES() {
    Proto.Fxn fxn;
    StringBuilder sb;

    fxn =
        (Proto.Fxn)
            om.bind(
                "host.platforms.SUN.SunSparc7$$create",
                new Proto.Fxn(
                    om.findStrict("host.platforms.SUN.SunSparc7.Module", "host.platforms.SUN"),
                    om.findStrict("host.platforms.SUN.SunSparc7.Instance", "host.platforms.SUN"),
                    2,
                    1,
                    false));
    fxn.addArg(0, "revision", $$T_Str, $$UNDEF);
    fxn.addArg(
        1,
        "__params",
        (Proto) om.findStrict("host.platforms.SUN.SunSparc7.Params", "host.platforms.SUN"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append("host$platforms$SUN$SunSparc7$$create = function( revision, __params ) {\n");
    sb.append("var __mod = xdc.om['host.platforms.SUN.SunSparc7'];\n");
    sb.append("var __inst = xdc.om['host.platforms.SUN.SunSparc7.Instance'].$$make();\n");
    sb.append("__inst.$$bind('$package', xdc.om['host.platforms.SUN']);\n");
    sb.append("__inst.$$bind('$index', __mod.$instances.length);\n");
    sb.append("__inst.$$bind('$category', 'Instance');\n");
    sb.append("__inst.$$bind('$args', {revision:revision});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$instances.$add(__inst);\n");
    sb.append("__inst.cpuCore = __mod.PARAMS.cpuCore;\n");
    sb.append("__inst.cpuCoreRevision = __mod.PARAMS.cpuCoreRevision;\n");
    sb.append("__inst.minProgUnitSize = __mod.PARAMS.minProgUnitSize;\n");
    sb.append("__inst.minDataUnitSize = __mod.PARAMS.minDataUnitSize;\n");
    sb.append("__inst.dataWordSize = __mod.PARAMS.dataWordSize;\n");
    sb.append("for (__p in __params) __inst[__p] = __params[__p];\n");
    sb.append("var save = xdc.om.$curpkg;\n");
    sb.append("xdc.om.$$bind('$curpkg', __mod.$package.$name);\n");
    sb.append("__mod.instance$meta$init.$fxn.apply(__inst, [revision]);\n");
    sb.append("xdc.om.$$bind('$curpkg', save);\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return __inst;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
    fxn =
        (Proto.Fxn)
            om.bind(
                "host.platforms.SUN.SunSparc7$$construct",
                new Proto.Fxn(
                    om.findStrict("host.platforms.SUN.SunSparc7.Module", "host.platforms.SUN"),
                    null,
                    3,
                    1,
                    false));
    fxn.addArg(
        0,
        "__obj",
        (Proto) om.findStrict("host.platforms.SUN.SunSparc7$$Object", "host.platforms.SUN"),
        null);
    fxn.addArg(1, "revision", $$T_Str, $$UNDEF);
    fxn.addArg(
        2,
        "__params",
        (Proto) om.findStrict("host.platforms.SUN.SunSparc7.Params", "host.platforms.SUN"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append(
        "host$platforms$SUN$SunSparc7$$construct = function( __obj, revision, __params ) {\n");
    sb.append("var __mod = xdc.om['host.platforms.SUN.SunSparc7'];\n");
    sb.append("var __inst = __obj;\n");
    sb.append("__inst.$$bind('$args', {revision:revision});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$objects.$add(__inst);\n");
    sb.append("__inst.cpuCore = __mod.PARAMS.cpuCore;\n");
    sb.append("__inst.cpuCoreRevision = __mod.PARAMS.cpuCoreRevision;\n");
    sb.append("__inst.minProgUnitSize = __mod.PARAMS.minProgUnitSize;\n");
    sb.append("__inst.minDataUnitSize = __mod.PARAMS.minDataUnitSize;\n");
    sb.append("__inst.dataWordSize = __mod.PARAMS.dataWordSize;\n");
    sb.append("for (__p in __params) __inst[__p] = __params[__p];\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return null;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
  }
예제 #4
0
  void Platform$$CREATES() {
    Proto.Fxn fxn;
    StringBuilder sb;

    fxn =
        (Proto.Fxn)
            om.bind(
                "host.platforms.SUN.Platform$$create",
                new Proto.Fxn(
                    om.findStrict("host.platforms.SUN.Platform.Module", "host.platforms.SUN"),
                    om.findStrict("host.platforms.SUN.Platform.Instance", "host.platforms.SUN"),
                    3,
                    2,
                    false));
    fxn.addArg(0, "name", $$T_Str, $$UNDEF);
    fxn.addArg(1, "args", $$T_Obj, $$UNDEF);
    fxn.addArg(
        2,
        "__params",
        (Proto) om.findStrict("host.platforms.SUN.Platform.Params", "host.platforms.SUN"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append("host$platforms$SUN$Platform$$create = function( name, args, __params ) {\n");
    sb.append("var __mod = xdc.om['host.platforms.SUN.Platform'];\n");
    sb.append("var __inst = xdc.om['host.platforms.SUN.Platform.Instance'].$$make();\n");
    sb.append("__inst.$$bind('$package', xdc.om['host.platforms.SUN']);\n");
    sb.append("__inst.$$bind('$index', __mod.$instances.length);\n");
    sb.append("__inst.$$bind('$category', 'Instance');\n");
    sb.append("__inst.$$bind('$args', {name:name, args:args});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$instances.$add(__inst);\n");
    sb.append("__inst.externalMemoryMap = __mod.PARAMS.externalMemoryMap;\n");
    sb.append("__inst.customMemoryMap = __mod.PARAMS.customMemoryMap;\n");
    sb.append("__inst.renameMap = __mod.PARAMS.renameMap;\n");
    sb.append("__inst.dataMemory = __mod.PARAMS.dataMemory;\n");
    sb.append("__inst.codeMemory = __mod.PARAMS.codeMemory;\n");
    sb.append("__inst.stackMemory = __mod.PARAMS.stackMemory;\n");
    sb.append("__inst.sectMap = __mod.PARAMS.sectMap;\n");
    sb.append("__inst.remoteHost = __mod.PARAMS.remoteHost;\n");
    sb.append("for (__p in __params) __inst[__p] = __params[__p];\n");
    sb.append("var save = xdc.om.$curpkg;\n");
    sb.append("xdc.om.$$bind('$curpkg', __mod.$package.$name);\n");
    sb.append("__mod.instance$meta$init.$fxn.apply(__inst, [name, args]);\n");
    sb.append("xdc.om.$$bind('$curpkg', save);\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return __inst;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
    fxn =
        (Proto.Fxn)
            om.bind(
                "host.platforms.SUN.Platform$$construct",
                new Proto.Fxn(
                    om.findStrict("host.platforms.SUN.Platform.Module", "host.platforms.SUN"),
                    null,
                    4,
                    2,
                    false));
    fxn.addArg(
        0,
        "__obj",
        (Proto) om.findStrict("host.platforms.SUN.Platform$$Object", "host.platforms.SUN"),
        null);
    fxn.addArg(1, "name", $$T_Str, $$UNDEF);
    fxn.addArg(2, "args", $$T_Obj, $$UNDEF);
    fxn.addArg(
        3,
        "__params",
        (Proto) om.findStrict("host.platforms.SUN.Platform.Params", "host.platforms.SUN"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append(
        "host$platforms$SUN$Platform$$construct = function( __obj, name, args, __params ) {\n");
    sb.append("var __mod = xdc.om['host.platforms.SUN.Platform'];\n");
    sb.append("var __inst = __obj;\n");
    sb.append("__inst.$$bind('$args', {name:name, args:args});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$objects.$add(__inst);\n");
    sb.append("__inst.externalMemoryMap = __mod.PARAMS.externalMemoryMap;\n");
    sb.append("__inst.customMemoryMap = __mod.PARAMS.customMemoryMap;\n");
    sb.append("__inst.renameMap = __mod.PARAMS.renameMap;\n");
    sb.append("__inst.dataMemory = __mod.PARAMS.dataMemory;\n");
    sb.append("__inst.codeMemory = __mod.PARAMS.codeMemory;\n");
    sb.append("__inst.stackMemory = __mod.PARAMS.stackMemory;\n");
    sb.append("__inst.sectMap = __mod.PARAMS.sectMap;\n");
    sb.append("__inst.remoteHost = __mod.PARAMS.remoteHost;\n");
    sb.append("for (__p in __params) __inst[__p] = __params[__p];\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return null;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
  }
예제 #5
0
  void ResourceBundle$$CREATES() {
    Proto.Fxn fxn;
    StringBuilder sb;

    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ResourceBundle$$create",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ResourceBundle.Module", "xdc.tools"),
                    om.findStrict("xdc.tools.ResourceBundle.Instance", "xdc.tools"),
                    3,
                    2,
                    false));
    fxn.addArg(0, "pkgName", $$T_Str, $$UNDEF);
    fxn.addArg(1, "lang", $$T_Str, $$UNDEF);
    fxn.addArg(
        2,
        "__params",
        (Proto) om.findStrict("xdc.tools.ResourceBundle.Params", "xdc.tools"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append("xdc$tools$ResourceBundle$$create = function( pkgName, lang, __params ) {\n");
    sb.append("var __mod = xdc.om['xdc.tools.ResourceBundle'];\n");
    sb.append("var __inst = xdc.om['xdc.tools.ResourceBundle.Instance'].$$make();\n");
    sb.append("__inst.$$bind('$package', xdc.om['xdc.tools']);\n");
    sb.append("__inst.$$bind('$index', __mod.$instances.length);\n");
    sb.append("__inst.$$bind('$category', 'Instance');\n");
    sb.append("__inst.$$bind('$args', {pkgName:pkgName, lang:lang});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$instances.$add(__inst);\n");
    sb.append("for (var __p in __params) __inst[__p] = __params[__p];\n");
    sb.append("var save = xdc.om.$curpkg;\n");
    sb.append("xdc.om.$$bind('$curpkg', __mod.$package.$name);\n");
    sb.append("__mod.instance$meta$init.$fxn.apply(__inst, [pkgName, lang]);\n");
    sb.append("xdc.om.$$bind('$curpkg', save);\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return __inst;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.ResourceBundle$$construct",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.ResourceBundle.Module", "xdc.tools"),
                    null,
                    4,
                    2,
                    false));
    fxn.addArg(
        0, "__obj", (Proto) om.findStrict("xdc.tools.ResourceBundle$$Object", "xdc.tools"), null);
    fxn.addArg(1, "pkgName", $$T_Str, $$UNDEF);
    fxn.addArg(2, "lang", $$T_Str, $$UNDEF);
    fxn.addArg(
        3,
        "__params",
        (Proto) om.findStrict("xdc.tools.ResourceBundle.Params", "xdc.tools"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append(
        "xdc$tools$ResourceBundle$$construct = function( __obj, pkgName, lang, __params ) {\n");
    sb.append("var __mod = xdc.om['xdc.tools.ResourceBundle'];\n");
    sb.append("var __inst = __obj;\n");
    sb.append("__inst.$$bind('$args', {pkgName:pkgName, lang:lang});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$objects.$add(__inst);\n");
    sb.append("for (var __p in __params) __inst[__p] = __params[__p];\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return null;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
  }
예제 #6
0
  void Cmdr$$CREATES() {
    Proto.Fxn fxn;
    StringBuilder sb;

    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.Cmdr$$create",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.Cmdr.Module", "xdc.tools"),
                    om.findStrict("xdc.tools.Cmdr.Instance", "xdc.tools"),
                    2,
                    1,
                    false));
    fxn.addArg(0, "cmdmod", $$T_Obj, $$UNDEF);
    fxn.addArg(
        1,
        "__params",
        (Proto) om.findStrict("xdc.tools.Cmdr.Params", "xdc.tools"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append("xdc$tools$Cmdr$$create = function( cmdmod, __params ) {\n");
    sb.append("var __mod = xdc.om['xdc.tools.Cmdr'];\n");
    sb.append("var __inst = xdc.om['xdc.tools.Cmdr.Instance'].$$make();\n");
    sb.append("__inst.$$bind('$package', xdc.om['xdc.tools']);\n");
    sb.append("__inst.$$bind('$index', __mod.$instances.length);\n");
    sb.append("__inst.$$bind('$category', 'Instance');\n");
    sb.append("__inst.$$bind('$args', {cmdmod:cmdmod});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$instances.$add(__inst);\n");
    sb.append("for (var __p in __params) __inst[__p] = __params[__p];\n");
    sb.append("var save = xdc.om.$curpkg;\n");
    sb.append("xdc.om.$$bind('$curpkg', __mod.$package.$name);\n");
    sb.append("__mod.instance$meta$init.$fxn.apply(__inst, [cmdmod]);\n");
    sb.append("xdc.om.$$bind('$curpkg', save);\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return __inst;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
    fxn =
        (Proto.Fxn)
            om.bind(
                "xdc.tools.Cmdr$$construct",
                new Proto.Fxn(
                    om.findStrict("xdc.tools.Cmdr.Module", "xdc.tools"), null, 3, 1, false));
    fxn.addArg(0, "__obj", (Proto) om.findStrict("xdc.tools.Cmdr$$Object", "xdc.tools"), null);
    fxn.addArg(1, "cmdmod", $$T_Obj, $$UNDEF);
    fxn.addArg(
        2,
        "__params",
        (Proto) om.findStrict("xdc.tools.Cmdr.Params", "xdc.tools"),
        Global.newObject());
    sb = new StringBuilder();
    sb.append("xdc$tools$Cmdr$$construct = function( __obj, cmdmod, __params ) {\n");
    sb.append("var __mod = xdc.om['xdc.tools.Cmdr'];\n");
    sb.append("var __inst = __obj;\n");
    sb.append("__inst.$$bind('$args', {cmdmod:cmdmod});\n");
    sb.append("__inst.$$bind('$module', __mod);\n");
    sb.append("__mod.$objects.$add(__inst);\n");
    sb.append("for (var __p in __params) __inst[__p] = __params[__p];\n");
    sb.append("__inst.$$bless();\n");
    sb.append("return null;\n");
    sb.append("}\n");
    Global.eval(sb.toString());
  }