File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed
core/src/main/java/org/bouncycastle/util Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -48,6 +48,32 @@ public static boolean isOverrideSet(String propertyName)
48
48
}
49
49
}
50
50
51
+ /**
52
+ * Return whether a particular override has been set to true.
53
+ *
54
+ * @param propertyName the property name for the override.
55
+ * @return true if the property is set to "true", false otherwise.
56
+ */
57
+ public static boolean isOverrideSet (String propertyName , boolean defIsTrue )
58
+ {
59
+ try
60
+ {
61
+ String value = getPropertyValue (propertyName );
62
+ if (value == null )
63
+ {
64
+ return defIsTrue ;
65
+ }
66
+ else
67
+ {
68
+ return isSetTrue (value );
69
+ }
70
+ }
71
+ catch (AccessControlException e )
72
+ {
73
+ return false ;
74
+ }
75
+ }
76
+
51
77
/**
52
78
* Return whether a particular override has been set to false.
53
79
*
You can’t perform that action at this time.
0 commit comments