Class: Google::Apis::AndroidmanagementV1::MigrationToken

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 token to initiate the migration of a device from being managed by a third- party DPC to being managed by Android Management API. A migration token is valid only for a single device.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ MigrationToken

Returns a new instance of MigrationToken.



3459
3460
3461
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3459

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

Instance Attribute Details

#additional_dataString

Immutable. Optional EMM-specified additional data. Once the device is migrated this will be populated in the migrationAdditionalData field of the Device resource. This must be at most 1024 characters. Corresponds to the JSON property additionalData

Returns:

  • (String)


3391
3392
3393
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3391

def additional_data
  @additional_data
end

#create_timeString

Output only. Time when this migration token was created. Corresponds to the JSON property createTime

Returns:

  • (String)


3396
3397
3398
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3396

def create_time
  @create_time
end

#deviceString

Output only. Once this migration token is used to migrate a device, the name of the resulting Device resource will be populated here, in the form enterprises/enterprise/devices/device. Corresponds to the JSON property device

Returns:

  • (String)


3403
3404
3405
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3403

def device
  @device
end

#device_idString

Required. Immutable. The id of the device, as in the Play EMM API. This corresponds to the deviceId parameter in Play EMM API's Devices.get (https:// developers.google.com/android/work/play/emm-api/v1/devices/get#parameters) call. Corresponds to the JSON property deviceId

Returns:

  • (String)


3411
3412
3413
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3411

def device_id
  @device_id
end

#expire_timeString

Immutable. The time when this migration token expires. This can be at most seven days from the time of creation. The migration token is deleted seven days after it expires. Corresponds to the JSON property expireTime

Returns:

  • (String)


3418
3419
3420
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3418

def expire_time
  @expire_time
end

#management_modeString

Required. Immutable. The management mode of the device or profile being migrated. Corresponds to the JSON property managementMode

Returns:

  • (String)


3424
3425
3426
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3424

def management_mode
  @management_mode
end

#nameString

Output only. The name of the migration token, which is generated by the server during creation, in the form enterprises/enterprise/migrationTokens/ migration_token. Corresponds to the JSON property name

Returns:

  • (String)


3431
3432
3433
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3431

def name
  @name
end

#policyString

Required. Immutable. The name of the policy initially applied to the enrolled device, in the form enterprises/enterprise/policies/policy. Corresponds to the JSON property policy

Returns:

  • (String)


3437
3438
3439
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3437

def policy
  @policy
end

#ttlString

Input only. The time that this migration token is valid for. This is input- only, and for returning a migration token the server will populate the expireTime field. This can be at most seven days. The default is seven days. Corresponds to the JSON property ttl

Returns:

  • (String)


3444
3445
3446
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3444

def ttl
  @ttl
end

#user_idString

Required. Immutable. The user id of the Managed Google Play account on the device, as in the Play EMM API. This corresponds to the userId parameter in Play EMM API's Devices.get (https://developers.google.com/android/work/play/ emm-api/v1/devices/get#parameters) call. Corresponds to the JSON property userId

Returns:

  • (String)


3452
3453
3454
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3452

def user_id
  @user_id
end

#valueString

Output only. The value of the migration token. Corresponds to the JSON property value

Returns:

  • (String)


3457
3458
3459
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3457

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
# File 'lib/google/apis/androidmanagement_v1/classes.rb', line 3464

def update!(**args)
  @additional_data = args[:additional_data] if args.key?(:additional_data)
  @create_time = args[:create_time] if args.key?(:create_time)
  @device = args[:device] if args.key?(:device)
  @device_id = args[:device_id] if args.key?(:device_id)
  @expire_time = args[:expire_time] if args.key?(:expire_time)
  @management_mode = args[:management_mode] if args.key?(:management_mode)
  @name = args[:name] if args.key?(:name)
  @policy = args[:policy] if args.key?(:policy)
  @ttl = args[:ttl] if args.key?(:ttl)
  @user_id = args[:user_id] if args.key?(:user_id)
  @value = args[:value] if args.key?(:value)
end