CFPreferencesAppValueIsForced(_:_:)
Determines whether or not a given key has been imposed on the user.
Declaration
func CFPreferencesAppValueIsForced(_ key: CFString, _ applicationID: CFString) -> BoolParameters
- key:
The key you are querying.
- applicationID:
The application’s ID, typically Kcfpreferencescurrentapplication. Do not pass
NULLor Kcfpreferencesanyapplication. Takes the form of a Java package name,com.foosoft.
Return Value
true if value of the key cannot be changed by the user, otherwise false.
Discussion
In cases where machines and/or users are under some kind of management, you should use this function to determine whether or not to disable UI elements corresponding to those preference keys.