Skip to content

Commit 454ed8c

Browse files
author
SDK Automation
committed
Generated from ac41d11e5195c9588faaf516d0f3707880ed6042
Marking the movestatus/moveresourcerror properties as readonly.
1 parent eea845a commit 454ed8c

File tree

3 files changed

+104
-65
lines changed

3 files changed

+104
-65
lines changed

sdk/regionmove/azure-mgmt-regionmove/azure/mgmt/regionmove/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@
66
# Changes may cause incorrect behavior and will be lost if the code is regenerated.
77
# --------------------------------------------------------------------------
88

9-
VERSION = "1.0.0b1"
9+
VERSION = "0.1.0-preview"

sdk/regionmove/azure-mgmt-regionmove/azure/mgmt/regionmove/models/_models.py

Lines changed: 51 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -370,12 +370,13 @@ class JobStatus(msrest.serialization.Model):
370370
371371
:ivar job_name: Defines the job name. Default value: "InitialSync".
372372
:vartype job_name: str
373-
:param job_progress: Gets or sets the monitoring job percentage.
374-
:type job_progress: str
373+
:ivar job_progress: Gets or sets the monitoring job percentage.
374+
:vartype job_progress: str
375375
"""
376376

377377
_validation = {
378-
'job_name': {'constant': True},
378+
'job_name': {'readonly': True, 'constant': True},
379+
'job_progress': {'readonly': True},
379380
}
380381

381382
_attribute_map = {
@@ -390,7 +391,8 @@ def __init__(
390391
**kwargs
391392
):
392393
super(JobStatus, self).__init__(**kwargs)
393-
self.job_progress = kwargs.get('job_progress', None)
394+
self.job_name = None
395+
self.job_progress = None
394396

395397

396398
class LBBackendAddressPoolResourceSettings(msrest.serialization.Model):
@@ -896,19 +898,28 @@ def __init__(
896898
class MoveResourceErrorBody(msrest.serialization.Model):
897899
"""An error response from the Azure Migrate service.
898900
899-
:param code: An identifier for the error. Codes are invariant and are intended to be consumed
901+
Variables are only populated by the server, and will be ignored when sending a request.
902+
903+
:ivar code: An identifier for the error. Codes are invariant and are intended to be consumed
900904
programmatically.
901-
:type code: str
902-
:param message: A message describing the error, intended to be suitable for display in a user
905+
:vartype code: str
906+
:ivar message: A message describing the error, intended to be suitable for display in a user
903907
interface.
904-
:type message: str
905-
:param target: The target of the particular error. For example, the name of the property in
908+
:vartype message: str
909+
:ivar target: The target of the particular error. For example, the name of the property in
906910
error.
907-
:type target: str
908-
:param details: A list of additional details about the error.
909-
:type details: list[~region_move_service_api.models.MoveResourceErrorBody]
911+
:vartype target: str
912+
:ivar details: A list of additional details about the error.
913+
:vartype details: list[~region_move_service_api.models.MoveResourceErrorBody]
910914
"""
911915

916+
_validation = {
917+
'code': {'readonly': True},
918+
'message': {'readonly': True},
919+
'target': {'readonly': True},
920+
'details': {'readonly': True},
921+
}
922+
912923
_attribute_map = {
913924
'code': {'key': 'code', 'type': 'str'},
914925
'message': {'key': 'message', 'type': 'str'},
@@ -921,10 +932,10 @@ def __init__(
921932
**kwargs
922933
):
923934
super(MoveResourceErrorBody, self).__init__(**kwargs)
924-
self.code = kwargs.get('code', None)
925-
self.message = kwargs.get('message', None)
926-
self.target = kwargs.get('target', None)
927-
self.details = kwargs.get('details', None)
935+
self.code = None
936+
self.message = None
937+
self.target = None
938+
self.details = None
928939

929940

930941
class MoveResourceFilter(msrest.serialization.Model):
@@ -1057,19 +1068,26 @@ def __init__(
10571068
class MoveResourceStatus(msrest.serialization.Model):
10581069
"""Defines the move resource status.
10591070
1060-
:param move_state: Defines the MoveResource states. Possible values include:
1071+
Variables are only populated by the server, and will be ignored when sending a request.
1072+
1073+
:ivar move_state: Defines the MoveResource states. Possible values include:
10611074
"AssignmentPending", "PreparePending", "PrepareInProgress", "PrepareFailed", "MovePending",
10621075
"MoveInProgress", "MoveFailed", "DiscardInProgress", "DiscardFailed", "CommitPending",
10631076
"CommitInProgress", "CommitFailed", "Committed".
1064-
:type move_state: str or ~region_move_service_api.models.MoveState
1077+
:vartype move_state: str or ~region_move_service_api.models.MoveState
10651078
:param job_status: Defines the job status.
10661079
:type job_status: ~region_move_service_api.models.JobStatus
10671080
:param errors: An error response from the azure region move service.
10681081
:type errors: ~region_move_service_api.models.MoveResourceError
1069-
:param target_id: Gets the Target ARM Id of the resource.
1070-
:type target_id: str
1082+
:ivar target_id: Gets the Target ARM Id of the resource.
1083+
:vartype target_id: str
10711084
"""
10721085

1086+
_validation = {
1087+
'move_state': {'readonly': True},
1088+
'target_id': {'readonly': True},
1089+
}
1090+
10731091
_attribute_map = {
10741092
'move_state': {'key': 'moveState', 'type': 'str'},
10751093
'job_status': {'key': 'jobStatus', 'type': 'JobStatus'},
@@ -1082,28 +1100,35 @@ def __init__(
10821100
**kwargs
10831101
):
10841102
super(MoveResourceStatus, self).__init__(**kwargs)
1085-
self.move_state = kwargs.get('move_state', None)
1103+
self.move_state = None
10861104
self.job_status = kwargs.get('job_status', None)
10871105
self.errors = kwargs.get('errors', None)
1088-
self.target_id = kwargs.get('target_id', None)
1106+
self.target_id = None
10891107

10901108

10911109
class MoveResourcePropertiesMoveStatus(MoveResourceStatus):
10921110
"""Defines the move resource status.
10931111
1094-
:param move_state: Defines the MoveResource states. Possible values include:
1112+
Variables are only populated by the server, and will be ignored when sending a request.
1113+
1114+
:ivar move_state: Defines the MoveResource states. Possible values include:
10951115
"AssignmentPending", "PreparePending", "PrepareInProgress", "PrepareFailed", "MovePending",
10961116
"MoveInProgress", "MoveFailed", "DiscardInProgress", "DiscardFailed", "CommitPending",
10971117
"CommitInProgress", "CommitFailed", "Committed".
1098-
:type move_state: str or ~region_move_service_api.models.MoveState
1118+
:vartype move_state: str or ~region_move_service_api.models.MoveState
10991119
:param job_status: Defines the job status.
11001120
:type job_status: ~region_move_service_api.models.JobStatus
11011121
:param errors: An error response from the azure region move service.
11021122
:type errors: ~region_move_service_api.models.MoveResourceError
1103-
:param target_id: Gets the Target ARM Id of the resource.
1104-
:type target_id: str
1123+
:ivar target_id: Gets the Target ARM Id of the resource.
1124+
:vartype target_id: str
11051125
"""
11061126

1127+
_validation = {
1128+
'move_state': {'readonly': True},
1129+
'target_id': {'readonly': True},
1130+
}
1131+
11071132
_attribute_map = {
11081133
'move_state': {'key': 'moveState', 'type': 'str'},
11091134
'job_status': {'key': 'jobStatus', 'type': 'JobStatus'},

sdk/regionmove/azure-mgmt-regionmove/azure/mgmt/regionmove/models/_models_py3.py

Lines changed: 52 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -406,12 +406,13 @@ class JobStatus(msrest.serialization.Model):
406406
407407
:ivar job_name: Defines the job name. Default value: "InitialSync".
408408
:vartype job_name: str
409-
:param job_progress: Gets or sets the monitoring job percentage.
410-
:type job_progress: str
409+
:ivar job_progress: Gets or sets the monitoring job percentage.
410+
:vartype job_progress: str
411411
"""
412412

413413
_validation = {
414-
'job_name': {'constant': True},
414+
'job_name': {'readonly': True, 'constant': True},
415+
'job_progress': {'readonly': True},
415416
}
416417

417418
_attribute_map = {
@@ -423,12 +424,11 @@ class JobStatus(msrest.serialization.Model):
423424

424425
def __init__(
425426
self,
426-
*,
427-
job_progress: Optional[str] = None,
428427
**kwargs
429428
):
430429
super(JobStatus, self).__init__(**kwargs)
431-
self.job_progress = job_progress
430+
self.job_name = None
431+
self.job_progress = None
432432

433433

434434
class LBBackendAddressPoolResourceSettings(msrest.serialization.Model):
@@ -988,19 +988,28 @@ def __init__(
988988
class MoveResourceErrorBody(msrest.serialization.Model):
989989
"""An error response from the Azure Migrate service.
990990
991-
:param code: An identifier for the error. Codes are invariant and are intended to be consumed
991+
Variables are only populated by the server, and will be ignored when sending a request.
992+
993+
:ivar code: An identifier for the error. Codes are invariant and are intended to be consumed
992994
programmatically.
993-
:type code: str
994-
:param message: A message describing the error, intended to be suitable for display in a user
995+
:vartype code: str
996+
:ivar message: A message describing the error, intended to be suitable for display in a user
995997
interface.
996-
:type message: str
997-
:param target: The target of the particular error. For example, the name of the property in
998+
:vartype message: str
999+
:ivar target: The target of the particular error. For example, the name of the property in
9981000
error.
999-
:type target: str
1000-
:param details: A list of additional details about the error.
1001-
:type details: list[~region_move_service_api.models.MoveResourceErrorBody]
1001+
:vartype target: str
1002+
:ivar details: A list of additional details about the error.
1003+
:vartype details: list[~region_move_service_api.models.MoveResourceErrorBody]
10021004
"""
10031005

1006+
_validation = {
1007+
'code': {'readonly': True},
1008+
'message': {'readonly': True},
1009+
'target': {'readonly': True},
1010+
'details': {'readonly': True},
1011+
}
1012+
10041013
_attribute_map = {
10051014
'code': {'key': 'code', 'type': 'str'},
10061015
'message': {'key': 'message', 'type': 'str'},
@@ -1010,18 +1019,13 @@ class MoveResourceErrorBody(msrest.serialization.Model):
10101019

10111020
def __init__(
10121021
self,
1013-
*,
1014-
code: Optional[str] = None,
1015-
message: Optional[str] = None,
1016-
target: Optional[str] = None,
1017-
details: Optional[List["MoveResourceErrorBody"]] = None,
10181022
**kwargs
10191023
):
10201024
super(MoveResourceErrorBody, self).__init__(**kwargs)
1021-
self.code = code
1022-
self.message = message
1023-
self.target = target
1024-
self.details = details
1025+
self.code = None
1026+
self.message = None
1027+
self.target = None
1028+
self.details = None
10251029

10261030

10271031
class MoveResourceFilter(msrest.serialization.Model):
@@ -1165,19 +1169,26 @@ def __init__(
11651169
class MoveResourceStatus(msrest.serialization.Model):
11661170
"""Defines the move resource status.
11671171
1168-
:param move_state: Defines the MoveResource states. Possible values include:
1172+
Variables are only populated by the server, and will be ignored when sending a request.
1173+
1174+
:ivar move_state: Defines the MoveResource states. Possible values include:
11691175
"AssignmentPending", "PreparePending", "PrepareInProgress", "PrepareFailed", "MovePending",
11701176
"MoveInProgress", "MoveFailed", "DiscardInProgress", "DiscardFailed", "CommitPending",
11711177
"CommitInProgress", "CommitFailed", "Committed".
1172-
:type move_state: str or ~region_move_service_api.models.MoveState
1178+
:vartype move_state: str or ~region_move_service_api.models.MoveState
11731179
:param job_status: Defines the job status.
11741180
:type job_status: ~region_move_service_api.models.JobStatus
11751181
:param errors: An error response from the azure region move service.
11761182
:type errors: ~region_move_service_api.models.MoveResourceError
1177-
:param target_id: Gets the Target ARM Id of the resource.
1178-
:type target_id: str
1183+
:ivar target_id: Gets the Target ARM Id of the resource.
1184+
:vartype target_id: str
11791185
"""
11801186

1187+
_validation = {
1188+
'move_state': {'readonly': True},
1189+
'target_id': {'readonly': True},
1190+
}
1191+
11811192
_attribute_map = {
11821193
'move_state': {'key': 'moveState', 'type': 'str'},
11831194
'job_status': {'key': 'jobStatus', 'type': 'JobStatus'},
@@ -1188,35 +1199,40 @@ class MoveResourceStatus(msrest.serialization.Model):
11881199
def __init__(
11891200
self,
11901201
*,
1191-
move_state: Optional[Union[str, "MoveState"]] = None,
11921202
job_status: Optional["JobStatus"] = None,
11931203
errors: Optional["MoveResourceError"] = None,
1194-
target_id: Optional[str] = None,
11951204
**kwargs
11961205
):
11971206
super(MoveResourceStatus, self).__init__(**kwargs)
1198-
self.move_state = move_state
1207+
self.move_state = None
11991208
self.job_status = job_status
12001209
self.errors = errors
1201-
self.target_id = target_id
1210+
self.target_id = None
12021211

12031212

12041213
class MoveResourcePropertiesMoveStatus(MoveResourceStatus):
12051214
"""Defines the move resource status.
12061215
1207-
:param move_state: Defines the MoveResource states. Possible values include:
1216+
Variables are only populated by the server, and will be ignored when sending a request.
1217+
1218+
:ivar move_state: Defines the MoveResource states. Possible values include:
12081219
"AssignmentPending", "PreparePending", "PrepareInProgress", "PrepareFailed", "MovePending",
12091220
"MoveInProgress", "MoveFailed", "DiscardInProgress", "DiscardFailed", "CommitPending",
12101221
"CommitInProgress", "CommitFailed", "Committed".
1211-
:type move_state: str or ~region_move_service_api.models.MoveState
1222+
:vartype move_state: str or ~region_move_service_api.models.MoveState
12121223
:param job_status: Defines the job status.
12131224
:type job_status: ~region_move_service_api.models.JobStatus
12141225
:param errors: An error response from the azure region move service.
12151226
:type errors: ~region_move_service_api.models.MoveResourceError
1216-
:param target_id: Gets the Target ARM Id of the resource.
1217-
:type target_id: str
1227+
:ivar target_id: Gets the Target ARM Id of the resource.
1228+
:vartype target_id: str
12181229
"""
12191230

1231+
_validation = {
1232+
'move_state': {'readonly': True},
1233+
'target_id': {'readonly': True},
1234+
}
1235+
12201236
_attribute_map = {
12211237
'move_state': {'key': 'moveState', 'type': 'str'},
12221238
'job_status': {'key': 'jobStatus', 'type': 'JobStatus'},
@@ -1227,13 +1243,11 @@ class MoveResourcePropertiesMoveStatus(MoveResourceStatus):
12271243
def __init__(
12281244
self,
12291245
*,
1230-
move_state: Optional[Union[str, "MoveState"]] = None,
12311246
job_status: Optional["JobStatus"] = None,
12321247
errors: Optional["MoveResourceError"] = None,
1233-
target_id: Optional[str] = None,
12341248
**kwargs
12351249
):
1236-
super(MoveResourcePropertiesMoveStatus, self).__init__(move_state=move_state, job_status=job_status, errors=errors, target_id=target_id, **kwargs)
1250+
super(MoveResourcePropertiesMoveStatus, self).__init__(job_status=job_status, errors=errors, **kwargs)
12371251

12381252

12391253
class MoveResourcePropertiesSourceResourceSettings(ResourceSettings):

0 commit comments

Comments
 (0)