Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //fasade.asc
- // First place that accept incoming RPC from client side.
- // ---------------------------------------------------------------------------------
- Client.prototype.__resolve = function(ctype) {
- // Check if a component class corresponding to ctype exists if so
- // return a new facade factory for ctype components
- if ( gFrameworkFC.components[ctype] != null )
- return this[ctype] = new FCFactory(this, ctype);
- // else do nothing, forcing a NetConnection.Call.Failed
- }
- // component.asc
- // Component inside
- // ---------------------------------------------------------------------------------
- FCComponent = function( derivedTypeName, derivedType ) {
- ..........
- derivedType.instances = new Object();
- // Provide a create method so non-dynamic classes can be created manually
- derivedType.create = function(name) { return this.instances[name] = new this(name); }
- ..........
- gFrameworkFC.registerComponent( derivedTypeName, derivedType );
- }
Add Comment
Please, Sign In to add comment