摘要:
简单工厂由工厂类,抽象产品类和具体产品类组成1.抽象产品接口package{ public interface IGraph { function draw():void }}2.产品工厂类package{ public class GrapFactory { public function GrapFactory() { } public static function factory(shape:String):IGraph { switch (shape) { case "circle": return new Circle(); break; case " 阅读全文
摘要:
package{ import com.bit101.components.HSlider; import com.bit101.components.InputText; import com.bit101.components.Label; import com.bit101.components.PushButton; import flash.display.Sprite; import flash.events.Event; import flash.events.MouseEvent; import flash.events.NetStatusEvent; import flash 阅读全文