HazelcastClientNewHazelcastClient Method (String)Hazelcast .Net Client Class Library
Creates a new hazelcast client using the given configuration xml file

Namespace: Hazelcast.Client
Assembly: Hazelcast.Net (in Hazelcast.Net.dll) Version: 3.8.0.1
Syntax

public static IHazelcastInstance NewHazelcastClient(
	string configFile
)

Parameters

configFile
Type: SystemString
The configuration file with full or relative path.

Return Value

Type: IHazelcastInstance
IHazelcastInstance.
Examples

//Full path
var hazelcastInstance = Hazelcast.NewHazelcastClient(@"C:\Users\user\Hazelcast.Net\hazelcast-client.xml");
var myMap = hazelcastInstance.GetMap("myMap");

//relative path
var hazelcastInstance = Hazelcast.NewHazelcastClient(@"..\Hazelcast.Net\Resources\hazelcast-client.xml");
var myMap = hazelcastInstance.GetMap("myMap");
See Also

Reference