Initializes the TileLayer.


Namespace: AspMap.Web
Assembly: AspMapNET (in AspMapNET.dll)

Syntax

Visual Basic (Declaration)
Public Sub Initialize( _ 
   ByVal maxRequests As Integer _ 
)
C#
public void Initialize(
   int maxRequests
)
C++
public:
 void Initialize(
   int maxRequests
) sealed 
J#
public void Initialize(
   int maxRequests
)
JScript
public  function Initialize(
   maxRequests : int
)

Parameters

maxRequests
Specifies the maximum number of concurrent requests. Valid values are from 1 to 64.

Remarks

This method must be called after all necessary layers have been added to the TileLayer.

This method lets you specify the number of concurrent tile image requests that can be handled at the same time.

Memory resources required to handle a single request are pre-allocated when the Initialize method is called. Handling each additional request will require an additional amount of memory as for the single request.

An optimal value of the maxRequests parameter depends on the memory available for the application and the number of processors. As a starting point, set it to the number of available processors. The load will be distributed evenly among all the processors.

Example

 Copy Code
tileLayer.Initialize(System.Environment.ProcessorCount);

See Also