Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

esjava

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

esjava - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

20

bin/binding/ScopeVisitor.js

@@ -312,3 +312,3 @@ // Generated by CoffeeScript 1.10.0

_methods.each(function(k, v) {
var c, o;
var c, instances, o, statics;
o = (function() {

@@ -325,3 +325,3 @@ var i, len, results;

})();
if (((function() {
statics = (function() {
var i, len, results;

@@ -332,14 +332,15 @@ results = [];

if (c["static"]) {
results.push(c);
results.push(c.overload);
}
}
return results;
})()).length) {
})();
if (statics.length) {
ls.push({
name: k,
"static": true,
pattern: '$esjava$'
pars: statics
});
}
if (((function() {
instances = (function() {
var i, len, results;

@@ -350,11 +351,12 @@ results = [];

if (!c["static"]) {
results.push(c);
results.push(c.overload);
}
}
return results;
})()).length) {
})();
if (instances.length) {
return ls.push({
name: k,
"static": false,
pattern: '$esjava$'
pars: instances
});

@@ -361,0 +363,0 @@ }

@@ -47,19 +47,32 @@ // Generated by CoffeeScript 1.10.0

return su(function() {
var args, binding, body, call, decls, expr, i, id, j, len, lit, mem, meth, overload, prop, ref, rest;
id = arguments[0], decls = arguments[1], args = 4 <= arguments.length ? slice.call(arguments, 2, i = arguments.length - 1) : (i = 2, []), binding = arguments[i++];
ref = binding.ls_potential_overloads();
var __args, __binding, __decls, __id, body, call, cases, def_call, discriminant, expr, i, j, len, meth, nm, o, par_cnt, ref, rest, sw, test;
__id = arguments[0], __decls = arguments[1], __args = 4 <= arguments.length ? slice.call(arguments, 2, i = arguments.length - 1) : (i = 2, []), __binding = arguments[i++];
ref = __binding.ls_potential_overloads();
for (j = 0, len = ref.length; j < len; j++) {
overload = ref[j];
lit = builders.literal(overload.name + overload.pattern);
o = ref[j];
expr = o["static"] ? __binding.class_id : builders.thisExpression();
rest = builders.identifier('args');
prop = builders.memberExpression(rest, builders.identifier('length'));
prop = builders.binaryExpression('+', lit, prop);
expr = overload["static"] ? binding.class_id : builders.thisExpression();
mem = builders.memberExpression(expr, prop, true);
call = builders.callExpression(mem, [builders.spreadElement(rest)]);
body = builders.blockStatement([builders.returnStatement(call)]);
meth = builders.identifier(overload.name);
decls.push(make_method(meth, [builders.restElement(rest)], body, overload["static"]));
cases = (function() {
var k, len1, ref1, results;
ref1 = o.pars;
results = [];
for (k = 0, len1 = ref1.length; k < len1; k++) {
par_cnt = ref1[k];
nm = builders.identifier(__binding.overload(o.name, new Array(par_cnt)));
call = builders.memberExpression(expr, nm, false);
call = builders.callExpression(call, [builders.spreadElement(rest)]);
test = builders.literal(par_cnt);
results.push(builders.switchCase(test, [builders.returnStatement(call)]));
}
return results;
})();
discriminant = builders.memberExpression(rest, builders.identifier('length'));
sw = builders.switchStatement(discriminant, cases);
meth = builders.identifier(o.name);
def_call = builders.memberExpression(builders["super"](), meth);
def_call = builders.callExpression(def_call, [builders.spreadElement(rest)]);
body = builders.blockStatement([sw, builders.returnStatement(def_call)]);
__decls.push(make_method(meth, [builders.restElement(rest)], body, o["static"]));
}
return lazy.apply(null, [id, decls].concat(slice.call(args), [binding]));
return lazy.apply(null, [__id, __decls].concat(slice.call(__args), [__binding]));
});

@@ -66,0 +79,0 @@ };

{
"name": "esjava",
"version": "0.0.4",
"version": "0.0.5",
"description": "EXPERIMENTAL Java => ES6 Transpiler",

@@ -5,0 +5,0 @@ "dependencies": {

@@ -8,4 +8,4 @@ ### ESJava: *EXPERIMENTAL* Java => ES6 Transpiler

- Real World Examples: [Lucene Tokenizers](http://mazko.github.io/blog/posts/2015/10/21/kak-perestat-bespokoitsia-i-nachat-portirovat/)
- Real World Examples: [Lucene Tokenizers](http://mazko.github.io/blog/posts/2015/10/21/kak-perestat-bespokoitsia-i-nachat-portirovat/) | [Snowball Stemmers](https://github.com/mazko/jssnowball)
- [Parser Only](http://mazko.github.io/jsjavaparser)

@@ -678,45 +678,109 @@ 'use strict';

yychar_fix(...args) {
return this['yychar_fix$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.yychar_fix$esjava$0(...args);
}
return super.yychar_fix(...args);
}
getText(...args) {
return this['getText$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.getText$esjava$1(...args);
}
return super.getText(...args);
}
setBufferSize(...args) {
return this['setBufferSize$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.setBufferSize$esjava$1(...args);
}
return super.setBufferSize(...args);
}
yyclose(...args) {
return this['yyclose$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.yyclose$esjava$0(...args);
}
return super.yyclose(...args);
}
yyreset(...args) {
return this['yyreset$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.yyreset$esjava$1(...args);
}
return super.yyreset(...args);
}
yystate(...args) {
return this['yystate$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.yystate$esjava$0(...args);
}
return super.yystate(...args);
}
yybegin(...args) {
return this['yybegin$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.yybegin$esjava$1(...args);
}
return super.yybegin(...args);
}
yytext(...args) {
return this['yytext$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.yytext$esjava$0(...args);
}
return super.yytext(...args);
}
yycharat(...args) {
return this['yycharat$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.yycharat$esjava$1(...args);
}
return super.yycharat(...args);
}
yylength(...args) {
return this['yylength$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.yylength$esjava$0(...args);
}
return super.yylength(...args);
}
yypushback(...args) {
return this['yypushback$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.yypushback$esjava$1(...args);
}
return super.yypushback(...args);
}
getNextToken(...args) {
return this['getNextToken$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.getNextToken$esjava$0(...args);
}
return super.getNextToken(...args);
}
ddd(...args) {
return this['ddd$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.ddd$esjava$0(...args);
case 1:
return this.ddd$esjava$1(...args);
}
return super.ddd(...args);
}
static dddstatic(...args) {
return ClassicTokenizerImpl['dddstatic$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return ClassicTokenizerImpl.dddstatic$esjava$1(...args);
}
return super.dddstatic(...args);
}
static overstatic(...args) {
return ClassicTokenizerImpl['overstatic$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return ClassicTokenizerImpl.overstatic$esjava$1(...args);
case 0:
return ClassicTokenizerImpl.overstatic$esjava$0(...args);
}
return super.overstatic(...args);
}

@@ -978,12 +1042,30 @@ }

test_instanceof(...args) {
return this['test_instanceof$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.test_instanceof$esjava$0(...args);
}
return super.test_instanceof(...args);
}
testyychar1(...args) {
return this['testyychar1$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.testyychar1$esjava$0(...args);
}
return super.testyychar1(...args);
}
testyycharover1(...args) {
return this['testyycharover1$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.testyycharover1$esjava$0(...args);
case 1:
return this.testyycharover1$esjava$1(...args);
}
return super.testyycharover1(...args);
}
test_abstract(...args) {
return this['test_abstract$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.test_abstract$esjava$0(...args);
}
return super.test_abstract(...args);
}

@@ -996,3 +1078,7 @@ }

test(...args) {
return this['test$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.test$esjava$0(...args);
}
return super.test(...args);
}

@@ -1230,6 +1316,16 @@ }

static MessageBox(...args) {
return Animal['MessageBox$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return Animal.MessageBox$esjava$1(...args);
}
return super.MessageBox(...args);
}
move(...args) {
return this['move$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.move$esjava$1(...args);
case 0:
return this.move$esjava$0(...args);
}
return super.move(...args);
}

@@ -1246,3 +1342,7 @@ }

move$0(...args) {
return this['move$0$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.move$0$esjava$0(...args);
}
return super.move$0(...args);
}

@@ -1259,3 +1359,7 @@ }

move$0(...args) {
return this['move$0$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.move$0$esjava$0(...args);
}
return super.move$0(...args);
}

@@ -1277,3 +1381,7 @@ }

static main(...args) {
return BabelEvaluate['main$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return BabelEvaluate.main$esjava$1(...args);
}
return super.main(...args);
}

@@ -1311,6 +1419,14 @@ }

hello(...args) {
return this['hello$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.hello$esjava$0(...args);
}
return super.hello(...args);
}
static hello_s(...args) {
return I_AM_IN_COMPILATION_UNIT_Animal['hello_s$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return I_AM_IN_COMPILATION_UNIT_Animal.hello_s$esjava$0(...args);
}
return super.hello_s(...args);
}

@@ -1358,6 +1474,14 @@ }

hello1(...args) {
return this['hello1$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.hello1$esjava$0(...args);
}
return super.hello1(...args);
}
static hello_s2(...args) {
return Horse2['hello_s2$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return Horse2.hello_s2$esjava$0(...args);
}
return super.hello_s2(...args);
}

@@ -1397,6 +1521,14 @@ }

hello1(...args) {
return this['hello1$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.hello1$esjava$0(...args);
}
return super.hello1(...args);
}
hello_self(...args) {
return this['hello_self$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return this.hello_self$esjava$0(...args);
}
return super.hello_self(...args);
}

@@ -1428,10 +1560,26 @@ }

static move(...args) {
return AnimalOverload['move$esjava$' + args.length](...args);
switch (args.length) {
case 2:
return AnimalOverload.move$esjava$2(...args);
}
return super.move(...args);
}
move(...args) {
return this['move$esjava$' + args.length](...args);
switch (args.length) {
case 1:
return this.move$esjava$1(...args);
case 0:
return this.move$esjava$0(...args);
}
return super.move(...args);
}
static move2(...args) {
return AnimalOverload['move2$esjava$' + args.length](...args);
switch (args.length) {
case 0:
return AnimalOverload.move2$esjava$0(...args);
case 2:
return AnimalOverload.move2$esjava$2(...args);
}
return super.move2(...args);
}
}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc