
    ]                         d Z ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddl	m
Z
 dd	iZ ej                  ej                  j                         G d
 dej                               Zy)z0recommender API insights Mark Dismissed command.    )absolute_import)division)unicode_literals)insight)base)flagsEXAMPLESz
        To mark an insight as DISMISSED:

          $ {command} abcd-1234 --project=project-id --location=global --insight-type=google.compute.firewall.Insight --etag=abc123
        c                   *    e Zd ZdZeZed        Zd Zy)MarkDismissedzMark an insight's state as DISMISSED.

     Mark an insight's state as DISMISSED. Can be applied to insights in ACTIVE
     state. The following are currently supported: project, billing_account,
     folder, and organization.
  c                 
   t        j                  |        | j                  dt        d       | j                  dddd       | j                  d	d
ddgd
       | j                  dddd       | j                  dddd       y)zArgs is called by calliope to gather arguments for this command.

    Args:
      parser: An argparse parser that you can use to add arguments that go on
        the command line after this command.
    INSIGHTz,Insight id which will be marked as dismissed)typehelpz
--locationLOCATIONTLocation)metavarrequiredr   z--recommendation-change-typezRecommendation change typedismissleave_unchanged)r   choicesr   z--insight-typeINSIGHT_TYPEzInsight Type of the insightsz--etagetagzEtag of a insight)r   r   r   N)r   AddParentFlagsToParseradd_argumentstr)parsers    2lib/surface/recommender/insights/mark_dismissed.pyArgszMarkDismissed.Args.   s     
  (
;  
 j4j  J
&,-.)	  +
 +	  -
 46I  K    c                     t        j                  | j                               }t        j                  |      }|j                  ||j                        S )zRun 'gcloud recommender insights mark-dismissed'.

    Args:
      args: argparse.Namespace, The arguments that this command was invoked
        with.

    Returns:
      The result insights after being marked as dismissed.
    )r   CreateClientReleaseTrackr   GetInsightNamer   r   )selfargsclientnames       r   RunzMarkDismissed.RunK   sD     !!$"3"3"56F%Ddii00r   N)	__name__
__module____qualname____doc__DETAILED_HELPdetailed_helpstaticmethodr   r(    r   r   r   r   #   s'      -K K81r   r   N)r,   
__future__r   r   r   "googlecloudsdk.api_lib.recommenderr   googlecloudsdk.callioper   &googlecloudsdk.command_lib.recommenderr   r-   ReleaseTracksr"   ALPHACommandr   r0   r   r   <module>r8      se    7 &  ' 6 ( 8 	 D%%++,31DLL 31 -31r   