Class AVExternalStorageDevice

  • All Implemented Interfaces:
    NSObject

    public class AVExternalStorageDevice
    extends NSObject
    AVExternalStorageDevice An AVExternalStorageDevice represents a physical external storage device connected to the device that can be used to store captured media assets. Each instance of AVExternalStorageDevice corresponds to a physical external storage device where captured media assets can be stored. Instances of AVExternalStorageDevice cannot be created directly. An array of all currently available external storage devices can be obtained using AVExternalStorageDeviceDiscoverySession. Instances of AVExternalStorageDevice can be used with AVCaptureFileOutput subclasses for writing media files. API-Since: 17.0
    • Constructor Detail

      • AVExternalStorageDevice

        protected AVExternalStorageDevice​(org.moe.natj.general.Pointer peer)
    • Method Detail

      • accessInstanceVariablesDirectly

        public static boolean accessInstanceVariablesDirectly()
      • authorizationStatus

        public static long authorizationStatus()
        [@property] authorizationStatus Returns the client's authorization status for capturing onto an external storage device connected to this device. This method returns the AVAuthorizationStatus of the client for capturing onto an external storage device connected to this device. If the status is AVAuthorizationStatusNotDetermined, you may use the +requestAccessWithCompletionHandler: method to request access by prompting the user.
      • automaticallyNotifiesObserversForKey

        public static boolean automaticallyNotifiesObserversForKey​(@NotNull
                                                                   @NotNull java.lang.String key)
      • cancelPreviousPerformRequestsWithTarget

        public static void cancelPreviousPerformRequestsWithTarget​(@NotNull
                                                                   @NotNull java.lang.Object aTarget)
      • cancelPreviousPerformRequestsWithTargetSelectorObject

        public static void cancelPreviousPerformRequestsWithTargetSelectorObject​(@NotNull
                                                                                 @NotNull java.lang.Object aTarget,
                                                                                 @NotNull
                                                                                 @NotNull org.moe.natj.objc.SEL aSelector,
                                                                                 @Nullable
                                                                                 @Nullable java.lang.Object anArgument)
      • classFallbacksForKeyedArchiver

        @NotNull
        public static @NotNull NSArray<java.lang.String> classFallbacksForKeyedArchiver()
      • classForKeyedUnarchiver

        @NotNull
        public static @NotNull org.moe.natj.objc.Class classForKeyedUnarchiver()
      • debugDescription_static

        public static java.lang.String debugDescription_static()
      • description_static

        public static java.lang.String description_static()
      • displayName

        @Nullable
        public @Nullable java.lang.String displayName()
        [@property] displayName Display name of the external storage device. This property can be used for displaying the name of an external storage device in a user interface. Will return nil if we fail to extract information from external storage device.
      • freeSize

        public long freeSize()
        [@property] freeSize Current free size in bytes. This property represents the free size available on the external storage device. Will return -1 if we fail to extract information from external storage device.
      • hash_static

        public static long hash_static()
      • instanceMethodSignatureForSelector

        public static NSMethodSignature instanceMethodSignatureForSelector​(org.moe.natj.objc.SEL aSelector)
      • instancesRespondToSelector

        public static boolean instancesRespondToSelector​(org.moe.natj.objc.SEL aSelector)
      • isConnected

        public boolean isConnected()
        [@property] connected Indicates whether the external storage device is connected and available to the system. The property gives the current connection status of the external storage device.
      • isNotRecommendedForCaptureUse

        public boolean isNotRecommendedForCaptureUse()
        [@property] notRecommendedForCaptureUse Indicates whether the external storage device is not recommended for capture use. This property is used to let the client know if the external storage device is not suitable for camera capture.
      • isSubclassOfClass

        public static boolean isSubclassOfClass​(org.moe.natj.objc.Class aClass)
      • keyPathsForValuesAffectingValueForKey

        @NotNull
        public static @NotNull NSSet<java.lang.String> keyPathsForValuesAffectingValueForKey​(@NotNull
                                                                                             @NotNull java.lang.String key)
      • nextAvailableURLsWithPathExtensionsError

        @Nullable
        public @Nullable NSArray<? extends NSURL> nextAvailableURLsWithPathExtensionsError​(@NotNull
                                                                                           @NotNull NSArray<java.lang.String> extensionArray,
                                                                                           @Nullable
                                                                                           @Nullable org.moe.natj.general.ptr.Ptr<NSError> outError)
        nextAvailableURLsWithPathExtensions:error: Next available security-scoped, DCF compliant URL array with different path extensions. Configures the folder structure (create a DCIM folder if there isn't one already) on the external storage device to provide the next available unique DCF compliant security-scoped URL array with different path extensions. Security-scoped URL requires the use of startAccessingSecurityScopedResource, and stopAccessingSecurityScopedResource for access. [nextAvailableURL startAccessingSecurityScopedResource]; . . . // your code to capture image / video . . . [nextAvailableURL stopAccessingSecurityScopedResource]; Use the +requestAccessWithCompletionHandler: method to request access to external storage device before getting the next available URL array else an error will be thrown.
        Parameters:
        extensionArray - An array of path extensions for the next available URL requested.
        outError - An out parameter with error information indicating why the URL could not be provided. If this method is successful, error will be nil.
        Returns:
        An array of DCF compliant security-scoped URL with all the path extensions requested.
      • requestAccessWithCompletionHandler

        public static void requestAccessWithCompletionHandler​(@NotNull
                                                              @NotNull AVExternalStorageDevice.Block_requestAccessWithCompletionHandler handler)
        requestAccessWithCompletionHandler: Requests access to capture onto an external storage device connected to this device, showing a dialog to the user if necessary. Use this method to request access to capture onto an external storage device connected to this device. This call will not block while the user is being asked for access, allowing the client to continue running. Until access has been granted, trying to capture into detected external storage devices will result in an error. The user is only asked for permission the first time the client requests access, later calls use the authorization status selected by the user. The completion handler is called on an arbitrary dispatch queue. It is the client's responsibility to ensure that any UIKit-related updates are called on the main queue or main thread as a result.
        Parameters:
        handler - A completion handler block called with the result of requesting access to capture onto an external storage device.
      • resolveClassMethod

        public static boolean resolveClassMethod​(org.moe.natj.objc.SEL sel)
      • resolveInstanceMethod

        public static boolean resolveInstanceMethod​(org.moe.natj.objc.SEL sel)
      • setVersion_static

        public static void setVersion_static​(long aVersion)
      • superclass_static

        public static org.moe.natj.objc.Class superclass_static()
      • totalSize

        public long totalSize()
        [@property] totalSize Total storage size in bytes. This property represents the total storage size available on the external storage device. Will return -1 if we fail to extract information from external storage device.
      • useStoredAccessor

        @Deprecated
        public static boolean useStoredAccessor()
        Deprecated.
      • uuid

        @Nullable
        public @Nullable NSUUID uuid()
        [@property] uuid A unique identifier for external storage device. This property can be used to select a specific external storage device with ImageCapture framework APIs to read media assets. Will return nil if we fail to extract information from external storage device. For example the string value of this property will match the value from [ICDevice UUIDString].
      • version_static

        public static long version_static()