public enum

Config.OptionPriority

extends java.lang.Enum<Config.OptionPriority>

 java.lang.Object

↳java.lang.Enum<Config.OptionPriority>

↳androidx.camera.core.impl.Config.OptionPriority

Overview

Defines the priorities for resolving conflicting options.

Priority must be declared from high priority to low priority.

Summary

Enum Constants
ALWAYS_OVERRIDEIt takes precedence over any other option values at the risk of causing unexpected behavior.
HIGH_PRIORITY_REQUIREDThis priority is higher than Config.OptionPriority.REQUIRED and Config.OptionPriority.OPTIONAL, and it is designed to override the options internally to work around some device specific issues.
OPTIONALThe lowest priority, it can be overridden by any other option value.
REQUIREDIt's a required option value in order to achieve expected CameraX behavior.
Methods
public static Config.OptionPriorityvalueOf(java.lang.String name)

public static Config.OptionPriorityvalues()

from java.lang.Enum<E>clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
from java.lang.ObjectgetClass, notify, notifyAll, wait, wait, wait

Enum Constants

ALWAYS_OVERRIDE

It takes precedence over any other option values at the risk of causing unexpected behavior.

If the same option is already set, the option with this priority will overwrite the value.

This priority should only be used to explicitly specify an option, such as used by Camera2Interop or Camera2CameraControl to override an option.

HIGH_PRIORITY_REQUIRED

This priority is higher than Config.OptionPriority.REQUIRED and Config.OptionPriority.OPTIONAL, and it is designed to override the options internally to work around some device specific issues.

When two option values are set with this priority, the newer value takes precedence over the old one. Options with this priority can still be overridden by Config.OptionPriority.ALWAYS_OVERRIDE which are normally used by Camera2Interop.

REQUIRED

It's a required option value in order to achieve expected CameraX behavior. It takes precedence over Config.OptionPriority.OPTIONAL option values.

If two values are set to the same option, the value with Config.OptionPriority.ALWAYS_OVERRIDE priority will overwrite this priority and can potentially cause unexpected behaviors.

If two values are set to the same option with this priority, it might indicate a programming error internally and an exception will be thrown when merging the configs.

OPTIONAL

The lowest priority, it can be overridden by any other option value. When two option values are set with this priority, the newer value takes precedence over the old one.

Methods

public static Config.OptionPriority values()

public static Config.OptionPriority valueOf(java.lang.String name)