Minimal steps required to create a custom elemenet in Polymer 1.0, without any aid from tools like Yeoman and Gulp.
I have used the Quick tour of Polymer as a reference.
- Install Node.
Minimal steps required to create a custom elemenet in Polymer 1.0, without any aid from tools like Yeoman and Gulp.
I have used the Quick tour of Polymer as a reference.
public class FaultInterceptor extends AbstractSoapInterceptor { | |
public FaultInterceptor() { | |
super(Phase.MARSHAL); | |
} | |
@Override | |
public void handleMessage(SoapMessage message) throws Fault { | |
Fault fault = (Fault) message.getContent(Exception.class); |
beforeEach(function() { | |
this.addMatchers({ | |
toBeInstanceOf: function(expectedInstance) { | |
var actual = this.actual; | |
var notText = this.isNot ? " not" : ""; | |
this.message = function() { | |
return "Expected " + actual.constructor.name + notText + " is instance of " + expectedInstance.name; | |
}; | |
return actual instanceof expectedInstance; | |
} |
object GetUser: Template() { | |
var id by SqlInt | |
var name by SqlString | |
override fun query() = """ | |
(select * from users where name = $name and id = $id) | |
union | |
(select * from deleted_user where id = $id) | |
""" | |
} |
This content moved here: https://exploringjs.com/impatient-js/ch_arrays.html#quickref-arrays
Table of Contents
var flattenObject = function(ob) { | |
var toReturn = {}; | |
for (var i in ob) { | |
if (!ob.hasOwnProperty(i)) continue; | |
if ((typeof ob[i]) == 'object') { | |
var flatObject = flattenObject(ob[i]); | |
for (var x in flatObject) { | |
if (!flatObject.hasOwnProperty(x)) continue; |
Most of us won’t be able to use/deploy JDK 8 in production for a looong time. But that shouldn’t stop us from using it, right?
It should be possible to sneak in JDK 8 in the back way, the same way we snuck in Groovy and other libraries we wanted to use.
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000