Class CameraPermissionHelper
- java.lang.Object
-
- androidx.fragment.app.Fragment
-
- com.cheetahdigital.uikit.helper.permissions.BasePermissionHelper
-
- com.cheetahdigital.uikit.helper.permissions.CameraPermissionHelper
-
- All Implemented Interfaces:
android.content.ComponentCallbacks
,android.view.View.OnCreateContextMenuListener
,androidx.activity.result.ActivityResultCaller
,androidx.lifecycle.HasDefaultViewModelProviderFactory
,androidx.lifecycle.LifecycleOwner
,androidx.lifecycle.ViewModelStoreOwner
,androidx.savedstate.SavedStateRegistryOwner
,ConfirmDialogFragment.ConfirmDialogListener
public class CameraPermissionHelper extends BasePermissionHelper
Camera permission helper class
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
CameraPermissionHelper.CameraPermissionCallback
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
TAG
-
Fields inherited from class com.cheetahdigital.uikit.helper.permissions.BasePermissionHelper
mActivity, mContext, mPermissions
-
-
Constructor Summary
Constructors Constructor Description CameraPermissionHelper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getPermissionRationale()
Set the description on why the permission is neededjava.lang.String[]
getPermissions()
Set the name of the permissions you need to checkvoid
onAttach(android.content.Context context)
protected void
onPermissionDenied()
Method called after permission was deniedprotected void
onPermissionGranted()
Method called after permission was granted-
Methods inherited from class com.cheetahdigital.uikit.helper.permissions.BasePermissionHelper
checkPermission, isGranted, onCancel, onConfirm, onCreate, onDetach, onRequestPermissionsResult, requestPermissions, shouldShowPermissionRationale, showPermissionRationale, showPermissionRationale
-
Methods inherited from class androidx.fragment.app.Fragment
dump, equals, getActivity, getAllowEnterTransitionOverlap, getAllowReturnTransitionOverlap, getArguments, getChildFragmentManager, getContext, getDefaultViewModelProviderFactory, getEnterTransition, getExitTransition, getFragmentManager, getHost, getId, getLayoutInflater, getLayoutInflater, getLifecycle, getLoaderManager, getParentFragment, getParentFragmentManager, getReenterTransition, getResources, getRetainInstance, getReturnTransition, getSavedStateRegistry, getSharedElementEnterTransition, getSharedElementReturnTransition, getString, getString, getTag, getTargetFragment, getTargetRequestCode, getText, getUserVisibleHint, getView, getViewLifecycleOwner, getViewLifecycleOwnerLiveData, getViewModelStore, hashCode, hasOptionsMenu, instantiate, instantiate, isAdded, isDetached, isHidden, isInLayout, isMenuVisible, isRemoving, isResumed, isStateSaved, isVisible, onActivityCreated, onActivityResult, onAttach, onAttachFragment, onConfigurationChanged, onContextItemSelected, onCreateAnimation, onCreateAnimator, onCreateContextMenu, onCreateOptionsMenu, onCreateView, onDestroy, onDestroyOptionsMenu, onDestroyView, onGetLayoutInflater, onHiddenChanged, onInflate, onInflate, onLowMemory, onMultiWindowModeChanged, onOptionsItemSelected, onOptionsMenuClosed, onPause, onPictureInPictureModeChanged, onPrepareOptionsMenu, onPrimaryNavigationFragmentChanged, onResume, onSaveInstanceState, onStart, onStop, onViewCreated, onViewStateRestored, postponeEnterTransition, postponeEnterTransition, registerForActivityResult, registerForActivityResult, registerForContextMenu, requestPermissions, requireActivity, requireArguments, requireContext, requireFragmentManager, requireHost, requireParentFragment, requireView, setAllowEnterTransitionOverlap, setAllowReturnTransitionOverlap, setArguments, setEnterSharedElementCallback, setEnterTransition, setExitSharedElementCallback, setExitTransition, setHasOptionsMenu, setInitialSavedState, setMenuVisibility, setReenterTransition, setRetainInstance, setReturnTransition, setSharedElementEnterTransition, setSharedElementReturnTransition, setTargetFragment, setUserVisibleHint, shouldShowRequestPermissionRationale, startActivity, startActivity, startActivityForResult, startActivityForResult, startIntentSenderForResult, startPostponedEnterTransition, toString, unregisterForContextMenu
-
-
-
-
Method Detail
-
onAttach
public void onAttach(android.content.Context context)
- Overrides:
onAttach
in classBasePermissionHelper
-
getPermissions
public java.lang.String[] getPermissions()
Description copied from class:BasePermissionHelper
Set the name of the permissions you need to check- Specified by:
getPermissions
in classBasePermissionHelper
- Returns:
- permissions to check
-
getPermissionRationale
public java.lang.String getPermissionRationale()
Description copied from class:BasePermissionHelper
Set the description on why the permission is needed- Specified by:
getPermissionRationale
in classBasePermissionHelper
- Returns:
- description
-
onPermissionGranted
protected void onPermissionGranted()
Description copied from class:BasePermissionHelper
Method called after permission was granted- Specified by:
onPermissionGranted
in classBasePermissionHelper
-
onPermissionDenied
protected void onPermissionDenied()
Description copied from class:BasePermissionHelper
Method called after permission was denied- Specified by:
onPermissionDenied
in classBasePermissionHelper
-
-