@SuppressWarnings("unchecked") public String register(String channel,String scope,Serializable user){
switch (Scope.of(scope,user)) {
case APPLICATION:
    return register(null,channel,APPLICATION_SCOPE,sessionScope,getViewScope(false));
case SESSION:
  return register(user,channel,sessionScope,APPLICATION_SCOPE,getViewScope(false));
case VIEW:
return register(user,channel,getViewScope(true),APPLICATION_SCOPE,sessionScope);
default :
throw new UnsupportedOperationException();
}
}

@ SuppressWarnings ( "unchecked" ) public String register ( String channel , String scope , Serializable user ) { switch ( Scope . of ( scope , user ) ) { case APPLICATION : return register ( null , channel , APPLICATION_SCOPE , sessionScope , getViewScope ( false ) ) ; case SESSION : return register ( user , channel , sessionScope , APPLICATION_SCOPE , getViewScope ( false ) ) ; case VIEW : return register ( user , channel , getViewScope ( true ) , APPLICATION_SCOPE , sessionScope ) ; default : throw new UnsupportedOperationException ( ) ; } }
register given channel on given scope and returns the web socket channel identifier .
