
    *                        S r SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJ	r	  SSK
Jr  S	S
S.rS	S
S.r " S S\5      r\	R"                  " \	R$                  R&                  5       " S S\\	R(                  5      5       r\	R"                  " \	R$                  R,                  5       " S S\\	R(                  5      5       rg)z;Command to promote migration jobs for a database migration.    )absolute_import)division)unicode_literals)migration_jobs)resource_args)base)flagszE
        Promote a Database Migration Service migration job.
        zf        To promote a migration job:

          $ {command} MIGRATION_JOB --region=us-central1
        )DESCRIPTIONEXAMPLESc                   .    \ rS rSrSr\S 5       rS rSrg)_Promote1   3Promote a Database Migration Service migration job.c                 2    [         R                  " U S5        g)Args 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. Positional arguments are allowed.
z
to promoteN)r   AddOnlyMigrationJobResourceArgsparsers    8lib/surface/database_migration/migration_jobs/promote.pyArgs_Promote.Args4   s     11&,G    c                     UR                   R                  R                  5       n[        R                  " U R                  5       5      nUR                  UR                  5       U5      $ )a  Promote a Database Migration Service migration job.

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

Returns:
  A dict object representing the operations resource describing the promote
  operation if the promote was successful.
)CONCEPTSmigration_jobParser   MigrationJobsClientReleaseTrackPromoteRelativeName)selfargsmigration_job_ref	mj_clients       r   Run_Promote.Run>   sX     3399;2243D3D3FGI&&( r    N)	__name__
__module____qualname____firstlineno____doc__staticmethodr   r%   __static_attributes__r'   r   r   r   r   1   s    ;H Hr   r   c                   ,    \ rS rSrSr\r\S 5       rSr	g)	PromoteGAR   r   c                 Z    [         R                  U 5        [        R                  " U 5        gr   N)r   r   mj_flags*AddMigrationJobObjectsConfigFlagForPromoter   s    r   r   PromoteGA.ArgsX   s     MM&77?r   r'   N)
r(   r)   r*   r+   r,   DETAILED_HELP_GAdetailed_helpr-   r   r.   r'   r   r   r0   r0   R   s    ;"-@ @r   r0   c                   ,    \ rS rSrSr\r\S 5       rSr	g)PromoteAlphad   r   c                 .    [         R                  U 5        gr3   )r   r   r   s    r   r   PromoteAlpha.Argsj   s     MM&r   r'   N)
r(   r)   r*   r+   r,   DETAILED_HELP_ALPHAr8   r-   r   r.   r'   r   r   r:   r:   d   s    ;%- r   r:   N)r,   
__future__r   r   r   )googlecloudsdk.api_lib.database_migrationr   r   googlecloudsdk.callioper   <googlecloudsdk.command_lib.database_migration.migration_jobsr	   r4   r>   r7   objectr   ReleaseTracksr   GACommandr0   ALPHAr:   r'   r   r   <module>rH      s    B &  ' D C ( Z		 		 v B D%%(()@$,, @ *@" D%%++,8T\\  -r   