0.0.8 • Published 11 years ago

strict-method v0.0.8

Weekly downloads
3
License
-
Repository
github
Last release
11 years ago

strictmethod

strict method

example

 var m = require("strict-method");

 var user = {
    _name:"leo",
    _age:22,
    change:m(String,{min:5},Number,function(name,age){
        this._name = name;
        this._age = age;
    })
 }

 user.change("brighthas",28); // not error.

 user.change("bri",28);  // throw error! must min > 5

install

0.0.8

11 years ago

0.0.7

11 years ago

0.0.6

11 years ago

0.0.4

11 years ago

0.0.3

11 years ago

0.0.2

11 years ago

0.0.1

11 years ago