Files
opensim/OpenGrid.Framework.Manager/GridServerManager.cs
gareth 64a98c7368 Finished off adding the new management API to gridserver
Updated VersionInfo.cs finally
Updated prebuild and rebuilt nant build files
Completed Management agent basics
2007-05-14 03:13:47 +00:00

37 lines
881 B
C#

using System;
using System.Collections;
using System.Collections.Generic;
using Nwc.XmlRpc;
namespace OpenGrid.Framework.Manager {
public class GridServerManager
{
public static GridManagerCallback thecallback;
public static string sendkey;
public static string recvkey;
public static XmlRpcResponse XmlRpcShutdownMethod(XmlRpcRequest request)
{
XmlRpcResponse response = new XmlRpcResponse();
Hashtable requestData = (Hashtable)request.Params[0];
Hashtable responseData = new Hashtable();
if(requestData["authkey"]!=recvkey) {
responseData["error"]="INVALID KEY";
} else {
responseData["msg"]="Shutdown command accepted";
responseData["authkey"]=sendkey;
thecallback("shutdown");
}
response.Value = responseData;
return response;
}
}
}