
    l                     b    S r SSKJr  SSKJr  SSKJr  SSKJr   " S S\R                  5      rg)	z5Core labels_util extended with GCF specific behavior.    )absolute_import)division)unicode_literals)labels_utilc                   ,    \ rS rSrSr\SS j5       rSrg)Diff   zComputes changes to labels.

Similar to the core class, but it allows specifying labels that will be
added if not present or removed either via --remove-labels or
--clear-labels.
Nc                     U(       a  UR                   nU(       a  0 nOSnU(       a  UO0 nUR                  (       a  UR                  UR                  5        U " XQR                  U5      $ )aV  Initializes a Diff based on the arguments in AddUpdateLabelsFlags.

Args:
  args: The parsed args
  enable_clear: whether --clear-labels flag is enabled
  required_labels: dict of labels that will be added unless they're removed
    explicitly or via clear

Returns:
  The label updates Diff that needs to be applied to the exisiting labels.
N)clear_labelsupdate_labelsupdateremove_labels)clsargsenable_clearrequired_labelsclearadditions         7lib/googlecloudsdk/command_lib/functions/labels_util.pyFromUpdateArgsDiff.FromUpdateArgs    sW     e	e"1rHood(()x++U33     )TN)__name__
__module____qualname____firstlineno____doc__classmethodr   __static_attributes__r   r   r   r   r      s     4 4r   r   N)r   
__future__r   r   r   $googlecloudsdk.command_lib.util.argsr   r   r   r   r   <module>r#      s(    < &  ' <4; 4r   