Class: Google::Apis::AndroidmanagementV1::Command

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/androidmanagement_v1/classes.rb,
lib/google/apis/androidmanagement_v1/representations.rb,
lib/google/apis/androidmanagement_v1/representations.rb

Overview

A command.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Command

Returns a new instance of Command.



589
590
591
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 589

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#create_timeString

The timestamp at which the command was created. The timestamp is automatically generated by the server. Corresponds to the JSON property createTime

Returns:

  • (String)


552
553
554
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 552

def create_time
  @create_time
end

#durationString

The duration for which the command is valid. The command will expire if not executed by the device during this time. The default duration if unspecified is ten minutes. There is no maximum duration. Corresponds to the JSON property duration

Returns:

  • (String)


559
560
561
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 559

def duration
  @duration
end

#error_codeString

If the command failed, an error code explaining the failure. This is not set when the command is cancelled by the caller. Corresponds to the JSON property errorCode

Returns:

  • (String)


565
566
567
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 565

def error_code
  @error_code
end

#new_passwordString

For commands of type RESET_PASSWORD, optionally specifies the new password. Corresponds to the JSON property newPassword

Returns:

  • (String)


570
571
572
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 570

def new_password
  @new_password
end

#reset_password_flagsArray<String>

For commands of type RESET_PASSWORD, optionally specifies flags. Corresponds to the JSON property resetPasswordFlags

Returns:

  • (Array<String>)


575
576
577
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 575

def reset_password_flags
  @reset_password_flags
end

#typeString

The type of the command. Corresponds to the JSON property type

Returns:

  • (String)


580
581
582
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 580

def type
  @type
end

#user_nameString

The resource name of the user that owns the device in the form enterprises/ enterpriseId/users/userId. This is automatically generated by the server based on the device the command is sent to. Corresponds to the JSON property userName

Returns:

  • (String)


587
588
589
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 587

def user_name
  @user_name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



594
595
596
597
598
599
600
601
602
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 594

def update!(**args)
  @create_time = args[:create_time] if args.key?(:create_time)
  @duration = args[:duration] if args.key?(:duration)
  @error_code = args[:error_code] if args.key?(:error_code)
  @new_password = args[:new_password] if args.key?(:new_password)
  @reset_password_flags = args[:reset_password_flags] if args.key?(:reset_password_flags)
  @type = args[:type] if args.key?(:type)
  @user_name = args[:user_name] if args.key?(:user_name)
end