This file contains 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
import twitter4j.*; | |
import twitter4j.auth.*; | |
import java.awt.image.BufferedImage; | |
import java.io.*; | |
import java.util.Date; | |
import javax.imageio.ImageIO; | |
import com.phybots.service.Camera; |
This file contains 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
import java.net.Socket; | |
public class HttpPortScan { | |
public static void main(String[] args) { | |
final String prefix = "192.168.1."; | |
for (int i = 1; i < 256; i ++) { | |
final int ip = i; | |
new Thread(new Runnable() { | |
public void run() { |
This file contains 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
package evernote; | |
import java.io.BufferedReader; | |
import java.io.BufferedWriter; | |
import java.io.FileWriter; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.io.UnsupportedEncodingException; | |
import java.net.HttpURLConnection; | |
import java.net.MalformedURLException; | |
import java.net.URL; |
This file contains 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
// Amazonの注文履歴をCSV形式にして出力するスクリプト | |
// | |
// 以下のスクリプトを参考に作成されました。 | |
// http://moroya.hatenablog.jp/entry/2013/06/03/225935 | |
// | |
// 使い方は以下のURLに書いてあります。 | |
// https://junkato.jp/ja/blog/2014/11/13/amazon-payment-history-as-csv/ | |
// | |
// CSVに成型しているのは14行目から定義されているformatEntryという関数なので、これを書き換えれば自由な書式で出力できます。 | |
(function(){ |
This file contains 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
// execute this code in the debug console to extract chair names from the CHI 2017 website. | |
// https://chi2017.acm.org/select-subcommittee.html | |
var chairs = []; | |
document.querySelectorAll('span.MyBolding').forEach((e) => { | |
if (e.childNodes[0].data == 'Subcommittee Chairs' || e.childNodes[0].data == 'Associate Chairs') { | |
var p = e.parentElement; | |
while (p.nextSibling) { | |
p = p.nextSibling; | |
if (! p.children || p.children.length <= 0) { | |
if (p.childNodes && p.childNodes[0]) chairs.push(p.childNodes[0].data); |
This file contains 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
<html><head><script src="//api.songle.jp/v2/api.js"></script><script> | |
function onSongleWidgetAPIReady(SongleWidget) { | |
// 音楽プレーヤーを表示する | |
var player = new SongleWidget.Player({ | |
accessToken: '00000005-UEXXuKd' // アクセストークン | |
, secretToken: '2XNyvxFcjKRjoaTAfFiLtdbQJF8rkPaV' // シークレットトークン | |
}); | |
player.useMedia( | |
'https://youtube.com/watch?v=xOKplMgHxxA', |
This file contains 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
<html><head><script src="//api.songle.jp/v2/api.js"></script><script> | |
function onSongleWidgetAPIReady(SongleWidget) { | |
// 音楽プレーヤーを初期化する | |
var player = new SongleWidget.Player({ | |
accessToken: '00000005-UEXXuKd' // アクセストークン | |
}); | |
player.addPlugin(new SongleWidget.Plugin.SongleSync()); | |
// 再生時刻を定期的に更新する |
This file contains 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 accessToken = "YOUR_WIO_NODE_ACCESS_TOKEN" | |
, accessTokenQuery = "?access_token=" + accessToken | |
, logsSheetName = "logs" | |
, graphSheetName = "graph" | |
, graphHours = 240 /* 10 days */; | |
function main() { | |
var data = retrieveData(); | |
appendRow(data); |
This file contains 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
<html><head><script src="//api.songle.jp/v2/api.js"></script><script> | |
function onSongleWidgetAPIReady(SongleWidget) { | |
// Show the music player | |
var player = new SongleWidget.Player({ | |
accessToken: 'foo' // Access token | |
, secretToken: 'bar' // Secret token | |
}); | |
player.useMedia( | |
'https://youtube.com/watch?v=xOKplMgHxxA', |
This file contains 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
interface FileIface { | |
path: string; | |
} | |
interface FileRequest extends FileIface { | |
mode?: string; | |
element?: HTMLElement; | |
} | |
interface FileResponse extends FileIface { |
OlderNewer