My code:
class Address{
public var $Street;
}
class Employee{
public var $ID:
public var $Name:
public var $Address;
}
$myEmployee = new Employee();
$myEmployee->Address = new Address();
Nasıl sokak şimdi girebilirim?
$street = $myEmployee->$Address->Street;
$street = $myEmployee->Address->Street;
Her ikisi de bana Eclipse uyarı verir. Ben düşünüyordum:
$street = $myEmployee['Address']->Street;
Bu doğru mudur?