[designPattern]add singleton and composite