Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
/**
* Basic usage:<p>
* <code>
* Environment env = new BasicIniEnvironment("classpath:shiro.ini");
* SecurityManager securityManager = env.getSecurityManager();
* </code>
*
*/
public class BasicIniEnvironment extends DefaultEnvironment {
public BasicIniEnvironment(Ini ini) {
setSecurityManager(new IniSecurityManagerFactory(ini).getInstance());
}
public BasicIniEnvironment(String iniResourcePath) {
this(Ini.fromResourcePath(iniResourcePath));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment