navigation/common/src/main/java/androidx/navigation/NavDestination.java
public void putAction(@IdRes int actionId, @NonNull NavAction action) {
        if (actionId == 0) {
            throw new IllegalArgumentException("Cannot have an action with actionId 0");
        }
        if (mActions == null) {
            mActions = new SparseArrayCompat<>();
        }
        mActions.put(actionId, action);
    }
/**
     * Sets a destination ID for an action ID.
     *
     * @param actionId action ID to bind
     * @param action action to associate with this action ID
     */
Sets a destination ID for an action ID.
@param actionId action ID to bind
@param action action to associate with this action ID
Sets a destination ID for an action ID . @param actionId action ID to bind @param action action to associate with this action ID
public void putAction(@IdRes int actionId, @NonNull NavAction action) {
        if (actionId == 0) {
            throw new IllegalArgumentException("Cannot have an action with actionId 0");
        }
        if (mActions == null) {
            mActions = new SparseArrayCompat<>();
        }
        mActions.put(actionId, action);
    }
public void putAction ( @ IdRes int actionId , @ NonNull NavAction action ) { if ( actionId == 0 ) { throw new IllegalArgumentException ( "Cannot have an action with actionId 0" ) ; } if ( mActions == null ) { mActions = new SparseArrayCompat < > ( ) ; } mActions . put ( actionId , action ) ; }
Sets a destination ID for an action ID.
Sets a destination ID for an action ID .