Amber is an implementation of the Smalltalk language that runs on top of the JavaScript runtime.
2012-04-23 00:05
435 查看
Amber is an implementation of the Smalltalk-80 language. It is designed to make client-side development faster and easier. It allows developers to write client-side heavy web applications in Smalltalk.
Amber includes an integrated development environment with a class browser, workspace, transcript, object inspector and debugger.
Amber is written in itself, including the parser and compiler, and compiles into efficient JavaScript, mapping one-to-one with the JS equivalent.
Try a right now!
You can join the Google Group or the #amber-lang IRC channel on freenode.
Tweet
webscraping - Python library for web scraping - Google Project Hosting
All code is pure Python and has been run across multiple Linux servers, Windows machines, as well as Google App Engine.
Amber includes an integrated development environment with a class browser, workspace, transcript, object inspector and debugger.
Amber is written in itself, including the parser and compiler, and compiles into efficient JavaScript, mapping one-to-one with the JS equivalent.
Try a right now!
You can join the Google Group or the #amber-lang IRC channel on freenode.
Tweet
webscraping - Python library for web scraping - Google Project Hosting
Overview
The webscraping library aims to make web scraping easier.All code is pure Python and has been run across multiple Linux servers, Windows machines, as well as Google App Engine.
Examples
common
>>> from webscraping import common >>> common.remove_tags('hello <b>world</b>!') 'hello world!' >>> common.extract_domain('http://www.google.com.au/tos.html') 'google.com.au' >>> common.unescape('<hello & world>') '<hello & world>' >>> common.extract_emails('hello richard AT sitescraper DOT net world') ['richard@sitescraper.net'] >>> cj = common.firefox_cookie() >>> opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(cj)) >>> html = opener.open(url).read() # use current firefox cookies to access url
download
>>> from webscraping import download >>> D = download.Download() >>> # crawl given domain >>> domain = ... >>> for url in D.crawl(domain): >>> html = D.cache" target=_blank>[/code][title2]pdict[url=#pdict]>>> from webscraping import pdict >>> cache = pdict.PersistentDict(CACHE_FILE) >>> cache['a'] = range(5) # pickle stored in sqlite database >>> 'a' in cache True >>> cache['a'] [0, 1, 2, 3, 4](see a further example [url=http://blog.sitescraper.net/2010/07/caching-crawled-webpages.html]here)xpath
>>> from webscraping import xpath >>> html = urllib2.urlopen(url).read() >>> xpath.parse(html, '/html/body/ul[2]/li[@class="info"]/div[1]') ['div content'] >>> xpath.parse(html, '/html/body/ul[2]/li[@class="info"]/a/@href') ['url1', 'url2', 'url3']
相关文章推荐
- RedBridge is an implementation of JSR223 on top of JRuby Embed API
- Here is an implementation of the summation of N factorial(N的阶乘求和)
- 奇怪的内存泄露 incorrect decrement of the reference count of an object that is not owned at this point by
- Incorrect decrement of the reference count of an object that is not owned at this point by the caller1
- android.util.AndroidRuntimeException Calling startActivity() from outside of an Activity context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want? com.uethinking.microvideo.manag
- It is possible that this issue is resolved by uninstalling an existing version of the apk if it is present, and then re-installing ___Error Installing APK
- Given an array of size n, find the majority element. The majority element is the element that appear
- Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack
- 【随】Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack 问题解决。
- Question 30: What is the order of destructor calls for an object of class Y inherited from class X that has an object of class A
- It is possible that this issue is resolved by uninstalling an existing version of the apk if it is
- The parameter is (or has an element that is) the wrong kind of geometry
- Incorrect decrement of the reference count of an object that is not owned at this point by the calle
- Count the number of bits that are on in an unsigned integer(计算一个无符整数中1Bit的个数)-- (1)
- Incorrect decrement of the reference count of an object that is not owned at this point by the caller1
- BUG: Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack.
- eclipse中js中ctrl+鼠标点击方法出现 the resource is not on the include path of a javaScript project
- exactly the kind of division of tasks that Gulp.js is built on
- Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack.
- Incorrect decrement of the reference count of an object that is not owned at this point by the calle