public abstract class FilesystemBasedAuthImpl extends Object implements AuthInterface
Modifier and Type | Field and Description |
---|---|
protected boolean |
isIdentified
Is Identified
|
protected String |
password
Password
|
protected String |
rootFromAuth
Relative Path after Authentication
|
protected SessionInterface |
session
SessionInterface
|
protected String |
user
User name
|
Modifier | Constructor and Description |
---|---|
protected |
FilesystemBasedAuthImpl(SessionInterface session) |
Modifier and Type | Method and Description |
---|---|
protected abstract void |
businessClean()
Business implementation of clean
|
void |
clear()
Clean object
|
String |
getAbsolutePath(String path)
Return the full path as a String (with mount point).
|
String |
getBusinessPath()
Return the relative path for this account according to the Business
(without true root of mount).
|
String |
getRelativePath(String file)
Return the relative path from a file (without mount point)
|
SessionInterface |
getSession() |
String |
getUser() |
boolean |
isIdentified()
Is the current Authentication OK for full identification.
|
protected abstract NextCommandReply |
setBusinessPassword(String password)
Set the password according to any implementation and could set the
rootFromAuth.
|
protected abstract String |
setBusinessRootFromAuth() |
protected abstract NextCommandReply |
setBusinessUser(String user)
Set the user according to any implementation and could set the
rootFromAuth.
|
protected void |
setIsIdentified(boolean isIdentified)
Set the Authentication to Identified or Not
|
NextCommandReply |
setPassword(String password) |
protected void |
setRootFromAuth()
Set the root relative Path from current status of Authentication (should
be
the highest level for the
current authentication).
|
NextCommandReply |
setUser(String user) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getBaseDirectory, isAdmin, isBusinessPathValid
protected String user
protected String password
protected boolean isIdentified
protected final SessionInterface session
protected String rootFromAuth
protected FilesystemBasedAuthImpl(SessionInterface session)
session
- public final SessionInterface getSession()
getSession
in interface AuthInterface
protected abstract NextCommandReply setBusinessUser(String user) throws Reply421Exception, Reply530Exception
user
- Reply421Exception
- if there is a problem during the
authenticationReply530Exception
- if there is a problem during the
authenticationpublic final NextCommandReply setUser(String user) throws Reply421Exception, Reply530Exception
setUser
in interface AuthInterface
user
- the user to setReply421Exception
- if there is a problem during the
authenticationReply530Exception
- if there is a problem during the
authenticationpublic final String getUser()
getUser
in interface AuthInterface
protected abstract NextCommandReply setBusinessPassword(String password) throws Reply421Exception, Reply530Exception
password
- Reply421Exception
- if there is a problem during the
authenticationReply530Exception
- if there is a problem during the
authenticationpublic final NextCommandReply setPassword(String password) throws Reply421Exception, Reply530Exception
setPassword
in interface AuthInterface
password
- the password to setReply421Exception
- if there is a problem during the
authenticationReply530Exception
- if there is a problem during the
authenticationprotected final void setIsIdentified(boolean isIdentified)
isIdentified
- public final boolean isIdentified()
isIdentified
in interface AuthInterface
protected abstract String setBusinessRootFromAuth() throws Reply421Exception
Reply421Exception
- if the business root is not availableprotected void setRootFromAuth() throws Reply421Exception
Reply421Exception
- if the business root is not availablepublic final String getBusinessPath()
AuthInterface
getBusinessPath
in interface AuthInterface
protected abstract void businessClean()
public void clear()
clear
in interface AuthInterface
public final String getAbsolutePath(String path)
path
- relative path including business one (may be null or
empty)public final String getRelativePath(String file)
getRelativePath
in interface AuthInterface
file
- (full path with mount point)Copyright © 2009–2022 Waarp. All rights reserved.