code: function checkInitialValue(obj, props) {
  
    Object.keys(props).forEach(function(k) {
      var p = props[k], val = obj[k];
  
      if (util.isNullOrUndefined(val)) {
        if (p.nullable === false) {
          throw k + ' is not-nullable property but initial value is null';
        }
        return;
      }
  
      if (Struct.isStructType(p.type, val) || util.isType(p.type, val)) {
        return;
      }
  
      var mat = p.type.match(REGEXP_STRUCT_TYPE);
      if (mat) {
        // Definition is struct type but normal object given
        var structName = mat[1];
        checkInitialValue(val, Struct.structs[structName]);
        // Auto boxing
        obj[k] = Struct.create(structName, val);
        return;
      }
  
      throw k + ' must be ' + props[k].type +
            ' type. But initial value not matched';
    });
  
    // Check each condition formula
    Object.keys(props).forEach(function(k) {
      var p = props[k], val = obj[k];
      if (p.cond && !p.cond(val)) {
        throw 'Invalid value:' + k + '=' + String(val);
      }
    });
  
    Object.keys(obj).forEach(function(k) {
      if (!props.hasOwnProperty(k)) {
        throw 'Invalid property found:' + k;
      }
    });
  }
docs: Check initial object (internal)
  
  @param {Object} obj Check object.
  @param {Object} props Property definitions.