Package org.casbin.jcasbin.config
Class Config
java.lang.Object
org.casbin.jcasbin.config.Config
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final String
private static final String
private static final String
private ReentrantLock
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate boolean
addConfig adds a new section->key:value to the configuration.boolean
float
int
String[]
getStrings
(String key) static Config
newConfig create an empty configuration representation from file.static Config
newConfigFromText
(String text) newConfigFromText create an empty configuration representation from text.private void
private void
void
-
Field Details
-
DEFAULT_SECTION
- See Also:
-
DEFAULT_COMMENT
- See Also:
-
DEFAULT_COMMENT_SEM
- See Also:
-
lock
-
data
-
-
Constructor Details
-
Config
public Config()Config represents the configuration parser.
-
-
Method Details
-
newConfig
newConfig create an empty configuration representation from file.- Parameters:
confName
- the path of the model file.- Returns:
- the constructor of Config.
-
newConfigFromText
newConfigFromText create an empty configuration representation from text.- Parameters:
text
- the model text.- Returns:
- the constructor of Config.
-
addConfig
addConfig adds a new section->key:value to the configuration. -
parse
-
parseBuffer
- Throws:
IOException
-
getBool
-
getInt
-
getFloat
-
getString
-
getStrings
-
set
-
get
-