profile.createProperty("nick", OType.STRING).setMin("3").setMax("30").createIndex(INDEX_TYPE.UNIQUE);
profile.createProperty("name", OType.STRING).setMin("3").setMax("30").createIndex(INDEX_TYPE.NOTUNIQUE);
profile.createProperty("surname", OType.STRING).setMin("3").setMax("30");
profile.createProperty("registeredOn", OType.DATETIME).setMin("2010-01-01 00:00:00");
profile.createProperty("lastAccessOn", OType.DATETIME).setMin("2010-01-01 00:00:00");
profile.createProperty("photo", OType.TRANSIENT);
OClass whiz = database.getMetadata().getSchema().createClass("Whiz");
whiz.createProperty("id", OType.INTEGER);
whiz.createProperty("account", OType.LINK, profile);
whiz.createProperty("date", OType.DATE).setMin("2010-01-01");