Esempio n. 1
0
  def _ParseArgsForCommand(self, command, **kwargs):
    if command == 'login':
      return self._ParseLoginArgs(**kwargs)
    if command == 'version':
      return ['version']

    raise binary_operations.InvalidOperationForBinary(
        'Invalid Operation [{}] for kubectl-anthos'.format(command))
Esempio n. 2
0
 def _ParseArgsForCommand(self, command, **kwargs):
   if command == 'login':
     return self._ParseLoginArgs(**kwargs)
   elif command == 'create-login-config':
     return self._ParseCreateLoginConfigArgs(**kwargs)
   elif command == 'version':
     return ['version']
   else:
     raise binary_operations.InvalidOperationForBinary(
         'Invalid Operation [{}] for kubectl-anthos'.format(command))
Esempio n. 3
0
  def _ParseArgsForCommand(self, command, **kwargs):
    if command == 'get':
      return self._ParseGetArgs(**kwargs)
    if command == 'update':
      return self._ParseUpdateArgs(**kwargs)
    if command == 'desc':
      return self._ParseDescribeArgs(**kwargs)
    if command == 'init':
      return self._ParseInitArgs(**kwargs)
    if command == 'apply':
      return self._ParseApplyArgs(**kwargs)

    raise binary_operations.InvalidOperationForBinary(
        'Invalid Operation [{}] for anthoscli'.format(command))