This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| scala> val agent = new org.smop.mechanize.Mechanize | |
| agent: org.smop.mechanize.Mechanize = org.smop.mechanize.Mechanize@612e3937 | |
| scala> agent.get("http://www.smop.org/") | |
| res0: org.apache.http.HttpResponse = org.apache.http.message.BasicHttpResponse@3ab5b692 | |
| scala> agent.isSuccess | |
| res1: Boolean = true | |
| scala> agent.isHtml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var A, B, a, b, print, sys; | |
| var __hasProp = Object.prototype.hasOwnProperty, __extends = function(child, parent) { | |
| for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } | |
| function ctor() { this.constructor = child; } | |
| ctor.prototype = parent.prototype; | |
| child.prototype = new ctor; | |
| child.__super__ = parent.prototype; | |
| return child; | |
| }; | |
| sys = require('sys'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sys = require('sys') | |
| print = sys.print | |
| class A | |
| bar: -> | |
| print "A's bar\n" | |
| this.baz() | |
| baz: -> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var evaluatorString = | |
| '(function(stuff) {'+ | |
| ' return eval("(function() {"'+ | |
| '+stuff+'+ | |
| '"return "+evaluatorString+";'+ | |
| '})();");'+ | |
| '})'; | |
| var scope1 = eval(evaluatorString); | |
| var scope2 = scope1('var myVar = 42;'); |
NewerOlder