Emulating struct in PHP