code: public int toInt()
  	{
  		int day = ((year + 1900) * 12 + month) * 31 + (date - 1);
  
  		if( day < TIME_BEGIN )
  			day = TIME_BEGIN;
  		else if( day > TIME_END )
  			day = TIME_END;
  
  		return day;
  	}
docs: encodes the date into an int