PlaceBeanLocalBase.as 1.5 KB
/**
 * Generated by Gas3 v2.1.0 (Granite Data Services).
 *
 * WARNING: DO NOT CHANGE THIS FILE. IT MAY BE OVERWRITTEN EACH TIME YOU USE
 * THE GENERATOR. INSTEAD, EDIT THE INHERITED CLASS (PlaceBeanLocal.as).
 */

package fi.insomnia.bortal.beans {

    import fi.insomnia.bortal.model.Place;
    import mx.messaging.ChannelSet;
    import mx.messaging.config.ServerConfig;
    import mx.rpc.remoting.mxml.RemoteObject;

    public class PlaceBeanLocalBase extends RemoteObject {

        private var _initRemote:Boolean = false;

        private function initRemote():void {
            destination = "";
            channelSet = new ChannelSet();
            channelSet.addChannel(ServerConfig.getChannel(""));
            _initRemote = true;    
        }

        public function mergeChanges(arg0:Place):void {
            if (!_initRemote)
                initRemote();
            getOperation("mergeChanges").send(arg0);
        }

        public function addOperationListener(op:Function, type:String, handler:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void {
            if (op == this.mergeChanges) 
                this.getOperation("mergeChanges").addEventListener(type, handler, useCapture, priority, useWeakReference);
        }

        public function removeOperationListener(op:Function, event:String, handler:Function):void {
            if (op == this.mergeChanges) 
                this.getOperation("mergeChanges").removeEventListener(event, handler);
        }
    }
}