Browse Source

added "share"

Nicolas Cannasse 17 years ago
parent
commit
37afef6ede
1 changed files with 6 additions and 0 deletions
  1. 6 0
      std/haxe/remoting/Context.hx

+ 6 - 0
std/haxe/remoting/Context.hx

@@ -55,4 +55,10 @@ class Context {
 		return Reflect.callMethod(o,m,params);
 		return Reflect.callMethod(o,m,params);
 	}
 	}
 
 
+	public static function share( name : String, obj : {} ) : Context {
+		var ctx = new Context();
+		ctx.addObject(name,obj);
+		return ctx;
+	}
+
 }
 }