10.07.2015 Views

pdf - 395 K - Ecole des mines de Nantes

pdf - 395 K - Ecole des mines de Nantes

pdf - 395 K - Ecole des mines de Nantes

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

}return SystemInformation.ComputerName.ToLower();/// /// Returns the unique process ID of this process./// /// public static string GetProcessId(){return Process.GetCurrentProcess().Id.ToString();}resi<strong><strong>de</strong>s</strong>.host./// /// Returns the name of the computer on which the main host/// /// public static string GetMainHostName(){return MAIN_HOST;}/// /// Setups the agent infrastructure in this process as main/// public static void Install(){Install("localhost");}/// /// Setups the agent infrastructure in this process. Parameteris the machine/// name of the main host. If its value is "localhost" thenthis process/// becomes the main host./// /// public static void Install(string mainHostName){MAIN_HOST = mainHostName;NameServer.Install();DirectoryFacilitator.Install();// MessageTransporter does not need any install becauseof MSMQ}/// /// Returns whether the specified AgentAddress is this host./// /// public static bool IsThisHost(AgentAddress address){return ThisAddress.Equals(address);}/// /// Returns whether this process is the main host./// /// MSc EMOOSE Thesis – http://www.emn.fr/EMOOSE 66

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!