<?php
$size = new Size();
$point = new Point();
$point->left = 5;
$point->top = 5;
$rect = new Rect();
$rect->size = $size;
$rect->point = $point;
print_r($rect);
//In PHP there are no struct type
class Size {
public $width = 10;
public $height = 10;
}
class Point {
public $left;
public $top;
}
class Rect {
public $size;
public $point;
}