org.clazzes.util.http.sec
Interface CheckLoginService


public interface CheckLoginService

A base interface for remote services to check for logged in persons.


Method Summary
 String checkLogin()
           
 boolean checkPermission(String contextUrl)
          Check the permission of the logged in user on the given context URL.
 String getLocale()
           
 String getLoginUrl()
           
 String getTimeZone()
           
 void logout()
          Remove all login properties from the HTTP session and log the user out.
 

Method Detail

checkLogin

String checkLogin()
                  throws LoginRequiredException
Returns:
The logged in user.
Throws:
LoginRequiredException - if no user is logged in.

getLoginUrl

String getLoginUrl()
Returns:
The URL of the login servlet inside the login iframe.

getLocale

String getLocale()
Returns:
The locale used to log in the user. The format of the returned locale is in XML format (en, en-GB, de, de-AT,...) with hyphens to separate the language and the country, if the latter is known.

getTimeZone

String getTimeZone()
Returns:
The time zone used to log in the user. The returned string is an olson timezone ID as returned by TimeZone.getID().

checkPermission

boolean checkPermission(String contextUrl)
Check the permission of the logged in user on the given context URL.

Parameters:
contextUrl - The context Url.
Returns:
Whether the user is allowed to operate on the given context URL.

logout

void logout()
Remove all login properties from the HTTP session and log the user out.



Copyright © 2013. All Rights Reserved.