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
function obj1(){ | |
this.param1 = 1; | |
this.param2 = 2; | |
} | |
obj1.prototype.ProtoMethod = function(){ | |
this.param1 = 11; | |
this.param2 = 22; | |
} |
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
/* | |
App -> SpreadsheetFile -> aSheet -> Range -> Cell/Value | |
*/ | |
function readObject() { | |
objectPool = SpreadsheetApp.openById(read_sheet_id).getSheetByName('sheet1').getRange(1,1,20,20).getValues(); | |
} | |
function writeObject(){ | |
SpreadsheetApp.openById(write_sheet_id).getSheetByName('sheet3').getRange(1,1,20,20).setValues(objectPool); |
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
require "google_drive" | |
session = GoogleDrive.login( acc, pass) # セッションを取得 | |
ss = session.spreadsheet_by_key('key') # keyはURLに入ってるパラメータ | |
ws = ss.worksheet_by_title('title') # googleはワークシートって言ってなかった気がするけどworksheetで取得する | |
p ws.rows # これで中身みれる | |
max_r = ws.max_rows() | |
max_c = ws.max_cols() | |
for rows in 1..max_r # cellにアクセスするので1から。配列なら0からだけど。 | |
for cols in 1..max_c # 実際、0で開始するとエラーが出る。 | |
p ws[rows, cols] |
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
subview.methods.each do | method | p method end |
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
using UnityEngine; | |
using System.Collections; | |
public class Base : MonoBehaviour{ | |
protected class State | |
{ | |
const int cddc = 0; | |
} | |
} |
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
using UnityEngine; | |
using UnityEditor; | |
using System.Collections; | |
public class Question1Editor : Editor { | |
[MenuItem("Editor10/Question1")] | |
static void Question1_Basic(){} | |
[MenuItem("Editor10/Question1_ #&n",false)] | |
static bool Validateaaa() |
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
using UnityEngine; | |
using UnityEditor; | |
using System.Collections; | |
public class Question2Editor : EditorWindow { | |
[UnityEditor.MenuItem("Editor10/Question2/EditorWindow #&w")] | |
static void Q2_Basic() | |
{ | |
// CreateInstance<Class name>複数のウィンドウを作成する |
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
javascript: | |
var reg = /^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/; | |
var m = location.href.match(reg); | |
var params = m[5].split("/"); | |
var id = params[3]; | |
window.alert("https://drive.google.com/uc?export=view&id=" + id); |
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
using System; | |
using System.Collections.Generic; | |
namespace ConsoleApplication1 | |
{ | |
public static class SampleClass <T> | |
{ | |
public static T Member {get;set;} | |
static SampleClass() | |
{ |