Class: TokenServiceParameter

SuperMap.TokenServiceParameter

token application parameters class.

new SuperMap.TokenServiceParameter(options)

TokenServiceParameter.js, line 5
Name Type Description
options Object

token application parameters.

Name Type Default Description
username string

User name.

password string

Password.

clientType SuperMap.ClientType 'SuperMap.ClientType.NONE' optional

Token The client identification type of the application.

ip string optional

Required when clientType=IP.

referer string optional

Required when clientType=Referer. If you apply for a token by the specified URL, set the appropriate URL.

expiration number 60 optional

The validity period of the application token is calculated from the time the token is issued, in minutes.

Members

Token The client identification type of the application.

expirationnumber

The validity period of the application token is calculated from the time the token is issued, in minutes.

ipstring

Required when clientType=IP.

passwordstring

Password.

refererstring

Required when clientType=Referer. If you apply for a token by the specified URL, set the appropriate URL.

userNamestring

User name.

Methods

toJSON(){string}

TokenServiceParameter.js, line 62

Turn all information into a JSON string.

Returns:
Type Description
string The JSON object of the parameter.