private Promise<ActionResponse,ResourceException> internalHandleAction(String tokenId,Context context,ActionRequest request){
  final String action=request.getAction();
  final ActionHandler actionHandler=actionHandlers.get(action);
  if (actionHandler != null) {
    return actionHandler.handle(tokenId,context,request);
  }
 else {
    String message=String.format("Action %s not implemented for this resource",action);
    NotSupportedException e=new NotSupportedException(message);
    if (LOGGER.messageEnabled()) {
      LOGGER.message("SessionResource.actionInstance :: " + message,e);
    }
    return e.asPromise();
  }
}

private Promise < ActionResponse , ResourceException > internalHandleAction ( String tokenId , Context context , ActionRequest request ) { final String action = request . getAction ( ) ; final ActionHandler actionHandler = actionHandlers . get ( action ) ; if ( actionHandler != null ) { return actionHandler . handle ( tokenId , context , request ) ; } else { String message = String . format ( "Action %s not implemented for this resource" , action ) ; NotSupportedException e = new NotSupportedException ( message ) ; if ( LOGGER . messageEnabled ( ) ) { LOGGER . message ( "SessionResource.actionInstance :: " + message , e ) ; } return e . asPromise ( ) ; } }
handle the action specified by the user ( i . e . one of those in the validactions set ) .
