lib/complexTypes/ConnectionState.js
function checkConnectionState(key, value)
{
  if(typeof value != 'string')
    throw SyntaxError(key+' param should be a String, not '+typeof value);

  if(!value.match('DISCONNECTED|CONNECTED'))
    throw SyntaxError(key+' param is not one of [DISCONNECTED|CONNECTED] ('+value+')');
}
function checkConnectionState(key, value)
{
  if(typeof value != 'string')
    throw SyntaxError(key+' param should be a String, not '+typeof value);

  if(!value.match('DISCONNECTED|CONNECTED'))
    throw SyntaxError(key+' param is not one of [DISCONNECTED|CONNECTED] ('+value+')');
}
function checkConnectionState ( key , value ) { if ( typeof value != 'string' ) throw SyntaxError ( key + ' param should be a String, not ' + typeof value ) ; if ( ! value . match ( 'DISCONNECTED|CONNECTED' ) ) throw SyntaxError ( key + ' param is not one of [DISCONNECTED|CONNECTED] (' + value + ')' ) ; }
State of the connection.

@typedef core/complexTypes.ConnectionState

@type {(DISCONNECTED|CONNECTED)}
 
Checker for {@link module:core/complexTypes.ConnectionState}

@memberof module:core/complexTypes

@param {external:String} key
@param {module:core/complexTypes.ConnectionState} value
State of the connection .