Merge remote-tracking branch 'origin/master'
[chise/kage.git] / engine / buhin.js
diff --git a/engine/buhin.js b/engine/buhin.js
new file mode 100644 (file)
index 0000000..3fa0442
--- /dev/null
@@ -0,0 +1,24 @@
+function Buhin(number){\r
+  // method\r
+  function set(name, data){ // void\r
+    this.hash[name] = data;\r
+  }\r
+  Buhin.prototype.push = set;\r
+  Buhin.prototype.set = set;\r
+  \r
+  function search(name){ // string\r
+    if(this.hash[name]){\r
+      return this.hash[name];\r
+    }\r
+    return ""; // no data\r
+  }\r
+  Buhin.prototype.search = search;\r
+  \r
+  // property\r
+  this.hash = {};\r
+  \r
+  // initialize\r
+  // no operation\r
+  \r
+  return this;\r
+}\r