I want to set password policy on screen lock and now I use setPasswordQuality(ComponentName admin, int quality) in DevicePolicyManager but this method is deprecated on API 31 and they add new method(setRequiredPasswordComplexity(passwordComplexity : Int)). I can use this method in API < 31? If I can,how should I use it? https://developer.android.com/reference/android/app/admin/DevicePolicyManager#setRequiredPasswordComplexity(int)
            Asked
            
        
        
            Active
            
        
            Viewed 200 times
        
    2 Answers
1
            
            
        As the documentation already states the method was added in API 31 and since there is no backward compatibility library for this so this functionality can only be used on devices with api 31 or above
 
    
    
        Taranmeet Singh
        
- 1,199
- 1
- 11
- 14
- 
                    Thank you so much . I wanted to know this – nazanin Jan 15 '22 at 06:03
 
    