|
iiitAccessServer 1.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.iiit.access.server.plugins.parser.PropertyFileResolver
This is an example implementation of a resolver. This one reads its data from a property file.
Constructor Summary | |
PropertyFileResolver()
Creates a new instance of PropertyFileResolver |
|
PropertyFileResolver(String filename)
Creates a new instance of PropertyFileResolver |
Method Summary | |
void |
initialize(Configuration config)
Initializes the server |
Set |
resolve(ParserStackIf argStack)
Resolves the expression on top of the stack. |
Set |
resolve(ParserStackIf argStack,
String name)
The evaluation is optimized in such way that it only retrieves information regarding the given user name. |
void |
shutdown()
This method is called by the AccessServer when the background threads should stop because of a shutdown of the AccessServer itself. |
void |
start()
This method is called by the AccessServer when the background thread should start. |
boolean |
verifyUser(String uid)
Verifies whether a user exists in the user database. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public PropertyFileResolver()
public PropertyFileResolver(String filename) throws FileNotFoundException, IOException
filename
- The name of the property file to read.
FileNotFoundException
- if the file could not be found.
IOException
- if an error occurred when reading from the input file.Method Detail |
public void initialize(Configuration config)
initialize
in interface AccessServerPluginIf
config
- the configuration of the resolver. Currently the only parameter is
FileName
which defines the name of the property file to read.public void shutdown()
shutdown
in interface ThreadPluginIf
public void start()
start
in interface ThreadPluginIf
public Set resolve(ParserStackIf argStack) throws ParserException
resolve
in interface ResolverPluginIf
argStack
- This stack includes all expressions and subexpressions of the current tree
inside the orginal expression.
ParserException
- if there is something wrong with the expression. The most common cases are syntax
errors or circular references within the expression.public Set resolve(ParserStackIf argStack, String name) throws ParserException
resolve
in interface ResolverPluginIf
argStack
- This stack includes all expressions and subexpressions of the current tree
inside the orginal expression.name
- The name of the user for whom the expression should be resolved.
ParserException
- if there is something wrong with the expression. The most common cases are syntax
errors or circular references within the expression.public boolean verifyUser(String uid)
verifyUser
in interface ResolverPluginIf
uid
- the user ID.
|
iiitAccessServer 1.0 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |