@aws-sdk/client-efs 3.32.0 → 3.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +45 -0
- package/{dist/cjs → dist-cjs}/EFS.js +2 -3
- package/{dist/cjs → dist-cjs}/EFSClient.js +8 -9
- package/{dist/cjs → dist-cjs}/commands/CreateAccessPointCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/CreateFileSystemCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/CreateMountTargetCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/CreateTagsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DeleteAccessPointCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DeleteFileSystemCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DeleteFileSystemPolicyCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DeleteMountTargetCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DeleteTagsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeAccessPointsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeAccountPreferencesCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeBackupPolicyCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeFileSystemPolicyCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeFileSystemsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeLifecycleConfigurationCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeMountTargetSecurityGroupsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeMountTargetsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/DescribeTagsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/ListTagsForResourceCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/ModifyMountTargetSecurityGroupsCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/PutAccountPreferencesCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/PutBackupPolicyCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/PutFileSystemPolicyCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/PutLifecycleConfigurationCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/TagResourceCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/UntagResourceCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/commands/UpdateFileSystemCommand.js +2 -3
- package/{dist/cjs → dist-cjs}/endpoints.js +0 -1
- package/{dist/cjs → dist-cjs}/index.js +0 -1
- package/{dist/cjs → dist-cjs}/models/index.js +0 -1
- package/{dist/cjs → dist-cjs}/models/models_0.js +0 -1
- package/{dist/cjs → dist-cjs}/pagination/DescribeAccessPointsPaginator.js +1 -2
- package/{dist/cjs → dist-cjs}/pagination/DescribeFileSystemsPaginator.js +1 -2
- package/{dist/cjs → dist-cjs}/pagination/DescribeTagsPaginator.js +1 -2
- package/{dist/cjs → dist-cjs}/pagination/Interfaces.js +0 -1
- package/{dist/cjs → dist-cjs}/pagination/ListTagsForResourcePaginator.js +1 -2
- package/{dist/cjs → dist-cjs}/protocols/Aws_restJson1.js +16 -9
- package/{dist/cjs → dist-cjs}/runtimeConfig.browser.js +2 -2
- package/{dist/cjs → dist-cjs}/runtimeConfig.js +2 -2
- package/{dist/cjs → dist-cjs}/runtimeConfig.native.js +0 -1
- package/{dist/cjs → dist-cjs}/runtimeConfig.shared.js +1 -2
- package/{dist/es → dist-es}/EFS.js +3 -11
- package/{dist/es → dist-es}/EFSClient.js +2 -15
- package/{dist/es → dist-es}/commands/CreateAccessPointCommand.js +4 -37
- package/dist-es/commands/CreateFileSystemCommand.js +39 -0
- package/dist-es/commands/CreateMountTargetCommand.js +39 -0
- package/{dist/es → dist-es}/commands/CreateTagsCommand.js +4 -41
- package/{dist/es → dist-es}/commands/DeleteAccessPointCommand.js +4 -33
- package/dist-es/commands/DeleteFileSystemCommand.js +39 -0
- package/{dist/es → dist-es}/commands/DeleteFileSystemPolicyCommand.js +4 -33
- package/dist-es/commands/DeleteMountTargetCommand.js +39 -0
- package/dist-es/commands/DeleteTagsCommand.js +39 -0
- package/{dist/es → dist-es}/commands/DescribeAccessPointsCommand.js +4 -33
- package/{dist/es → dist-es}/commands/DescribeAccountPreferencesCommand.js +4 -31
- package/{dist/es → dist-es}/commands/DescribeBackupPolicyCommand.js +4 -30
- package/{dist/es → dist-es}/commands/DescribeFileSystemPolicyCommand.js +4 -31
- package/dist-es/commands/DescribeFileSystemsCommand.js +39 -0
- package/{dist/es → dist-es}/commands/DescribeLifecycleConfigurationCommand.js +4 -37
- package/{dist/es → dist-es}/commands/DescribeMountTargetSecurityGroupsCommand.js +4 -45
- package/{dist/es → dist-es}/commands/DescribeMountTargetsCommand.js +4 -37
- package/{dist/es → dist-es}/commands/DescribeTagsCommand.js +4 -40
- package/{dist/es → dist-es}/commands/ListTagsForResourceCommand.js +4 -31
- package/dist-es/commands/ModifyMountTargetSecurityGroupsCommand.js +39 -0
- package/{dist/es → dist-es}/commands/PutAccountPreferencesCommand.js +4 -33
- package/{dist/es → dist-es}/commands/PutBackupPolicyCommand.js +4 -30
- package/dist-es/commands/PutFileSystemPolicyCommand.js +39 -0
- package/dist-es/commands/PutLifecycleConfigurationCommand.js +39 -0
- package/{dist/es → dist-es}/commands/TagResourceCommand.js +4 -31
- package/{dist/es → dist-es}/commands/UntagResourceCommand.js +4 -31
- package/{dist/es → dist-es}/commands/UpdateFileSystemCommand.js +4 -31
- package/{dist/es → dist-es}/endpoints.js +1 -2
- package/{dist/types/index.d.ts → dist-es/index.js} +0 -0
- package/{dist/types/models/index.d.ts → dist-es/models/index.js} +0 -0
- package/{dist/es → dist-es}/models/models_0.js +0 -232
- package/{dist/es → dist-es}/pagination/DescribeAccessPointsPaginator.js +17 -30
- package/{dist/es → dist-es}/pagination/DescribeFileSystemsPaginator.js +17 -30
- package/{dist/es → dist-es}/pagination/DescribeTagsPaginator.js +17 -30
- package/dist-es/pagination/Interfaces.js +1 -0
- package/{dist/es → dist-es}/pagination/ListTagsForResourcePaginator.js +17 -30
- package/{dist/es → dist-es}/protocols/Aws_restJson1.js +750 -748
- package/{dist/es → dist-es}/runtimeConfig.browser.js +1 -5
- package/{dist/es → dist-es}/runtimeConfig.js +1 -5
- package/{dist/es → dist-es}/runtimeConfig.native.js +0 -4
- package/{dist/es → dist-es}/runtimeConfig.shared.js +1 -5
- package/{dist/types → dist-types}/EFS.d.ts +3 -3
- package/{dist/types → dist-types}/EFSClient.d.ts +9 -9
- package/{dist/types → dist-types}/commands/CreateAccessPointCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/CreateFileSystemCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/CreateMountTargetCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/CreateTagsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DeleteAccessPointCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DeleteFileSystemCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DeleteFileSystemPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DeleteMountTargetCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DeleteTagsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeAccessPointsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeAccountPreferencesCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeBackupPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeFileSystemPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeFileSystemsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeLifecycleConfigurationCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeMountTargetSecurityGroupsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeMountTargetsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/DescribeTagsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/ListTagsForResourceCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/ModifyMountTargetSecurityGroupsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/PutAccountPreferencesCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/PutBackupPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/PutFileSystemPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/PutLifecycleConfigurationCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/TagResourceCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/UntagResourceCommand.d.ts +2 -2
- package/{dist/types → dist-types}/commands/UpdateFileSystemCommand.d.ts +2 -2
- package/{dist/types → dist-types}/endpoints.d.ts +0 -0
- package/{index.ts → dist-types/index.d.ts} +0 -0
- package/{models/index.ts → dist-types/models/index.d.ts} +0 -0
- package/{dist/types → dist-types}/models/models_0.d.ts +0 -0
- package/{dist/types → dist-types}/pagination/DescribeAccessPointsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/pagination/DescribeFileSystemsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/pagination/DescribeTagsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/pagination/Interfaces.d.ts +1 -1
- package/{dist/types → dist-types}/pagination/ListTagsForResourcePaginator.d.ts +1 -1
- package/{dist/types → dist-types}/protocols/Aws_restJson1.d.ts +3 -3
- package/{dist/types → dist-types}/runtimeConfig.browser.d.ts +1 -0
- package/{dist/types/ts3.4 → dist-types}/runtimeConfig.d.ts +37 -36
- package/{dist/types → dist-types}/runtimeConfig.native.d.ts +1 -0
- package/{dist/types → dist-types}/runtimeConfig.shared.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/EFS.d.ts +3 -3
- package/{dist/types → dist-types}/ts3.4/EFSClient.d.ts +9 -9
- package/{dist/types → dist-types}/ts3.4/commands/CreateAccessPointCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/CreateFileSystemCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/CreateMountTargetCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/CreateTagsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DeleteAccessPointCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DeleteFileSystemCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DeleteFileSystemPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DeleteMountTargetCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DeleteTagsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeAccessPointsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeAccountPreferencesCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeBackupPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeFileSystemPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeFileSystemsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeLifecycleConfigurationCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeMountTargetSecurityGroupsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeMountTargetsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/DescribeTagsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/ListTagsForResourceCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/ModifyMountTargetSecurityGroupsCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/PutAccountPreferencesCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/PutBackupPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/PutFileSystemPolicyCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/PutLifecycleConfigurationCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/TagResourceCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/UntagResourceCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/commands/UpdateFileSystemCommand.d.ts +2 -2
- package/{dist/types → dist-types}/ts3.4/endpoints.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/models/index.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/models/models_0.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/pagination/DescribeAccessPointsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/pagination/DescribeFileSystemsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/pagination/DescribeTagsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/pagination/Interfaces.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/pagination/ListTagsForResourcePaginator.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/protocols/Aws_restJson1.d.ts +3 -3
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.browser.d.ts +1 -0
- package/{dist/types → dist-types/ts3.4}/runtimeConfig.d.ts +37 -36
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.native.d.ts +1 -0
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.shared.d.ts +0 -0
- package/package.json +52 -49
- package/EFS.ts +0 -1385
- package/EFSClient.ts +0 -362
- package/commands/CreateAccessPointCommand.ts +0 -101
- package/commands/CreateFileSystemCommand.ts +0 -147
- package/commands/CreateMountTargetCommand.ts +0 -235
- package/commands/CreateTagsCommand.ts +0 -105
- package/commands/DeleteAccessPointCommand.ts +0 -97
- package/commands/DeleteFileSystemCommand.ts +0 -108
- package/commands/DeleteFileSystemPolicyCommand.ts +0 -97
- package/commands/DeleteMountTargetCommand.ts +0 -127
- package/commands/DeleteTagsCommand.ts +0 -106
- package/commands/DescribeAccessPointsCommand.ts +0 -97
- package/commands/DescribeAccountPreferencesCommand.ts +0 -98
- package/commands/DescribeBackupPolicyCommand.ts +0 -94
- package/commands/DescribeFileSystemPolicyCommand.ts +0 -95
- package/commands/DescribeFileSystemsCommand.ts +0 -116
- package/commands/DescribeLifecycleConfigurationCommand.ts +0 -109
- package/commands/DescribeMountTargetSecurityGroupsCommand.ts +0 -120
- package/commands/DescribeMountTargetsCommand.ts +0 -101
- package/commands/DescribeTagsCommand.ts +0 -104
- package/commands/ListTagsForResourceCommand.ts +0 -95
- package/commands/ModifyMountTargetSecurityGroupsCommand.ts +0 -119
- package/commands/PutAccountPreferencesCommand.ts +0 -97
- package/commands/PutBackupPolicyCommand.ts +0 -94
- package/commands/PutFileSystemPolicyCommand.ts +0 -103
- package/commands/PutLifecycleConfigurationCommand.ts +0 -127
- package/commands/TagResourceCommand.ts +0 -95
- package/commands/UntagResourceCommand.ts +0 -95
- package/commands/UpdateFileSystemCommand.ts +0 -95
- package/dist/cjs/EFS.js.map +0 -1
- package/dist/cjs/EFSClient.js.map +0 -1
- package/dist/cjs/commands/CreateAccessPointCommand.js.map +0 -1
- package/dist/cjs/commands/CreateFileSystemCommand.js.map +0 -1
- package/dist/cjs/commands/CreateMountTargetCommand.js.map +0 -1
- package/dist/cjs/commands/CreateTagsCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteAccessPointCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteFileSystemCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteFileSystemPolicyCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteMountTargetCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteTagsCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeAccessPointsCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeAccountPreferencesCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeBackupPolicyCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeFileSystemPolicyCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeFileSystemsCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeLifecycleConfigurationCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeMountTargetSecurityGroupsCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeMountTargetsCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeTagsCommand.js.map +0 -1
- package/dist/cjs/commands/ListTagsForResourceCommand.js.map +0 -1
- package/dist/cjs/commands/ModifyMountTargetSecurityGroupsCommand.js.map +0 -1
- package/dist/cjs/commands/PutAccountPreferencesCommand.js.map +0 -1
- package/dist/cjs/commands/PutBackupPolicyCommand.js.map +0 -1
- package/dist/cjs/commands/PutFileSystemPolicyCommand.js.map +0 -1
- package/dist/cjs/commands/PutLifecycleConfigurationCommand.js.map +0 -1
- package/dist/cjs/commands/TagResourceCommand.js.map +0 -1
- package/dist/cjs/commands/UntagResourceCommand.js.map +0 -1
- package/dist/cjs/commands/UpdateFileSystemCommand.js.map +0 -1
- package/dist/cjs/endpoints.js.map +0 -1
- package/dist/cjs/index.js.map +0 -1
- package/dist/cjs/models/index.js.map +0 -1
- package/dist/cjs/models/models_0.js.map +0 -1
- package/dist/cjs/package.json +0 -93
- package/dist/cjs/pagination/DescribeAccessPointsPaginator.js.map +0 -1
- package/dist/cjs/pagination/DescribeFileSystemsPaginator.js.map +0 -1
- package/dist/cjs/pagination/DescribeTagsPaginator.js.map +0 -1
- package/dist/cjs/pagination/Interfaces.js.map +0 -1
- package/dist/cjs/pagination/ListTagsForResourcePaginator.js.map +0 -1
- package/dist/cjs/protocols/Aws_restJson1.js.map +0 -1
- package/dist/cjs/runtimeConfig.browser.js.map +0 -1
- package/dist/cjs/runtimeConfig.js.map +0 -1
- package/dist/cjs/runtimeConfig.native.js.map +0 -1
- package/dist/cjs/runtimeConfig.shared.js.map +0 -1
- package/dist/es/EFS.js.map +0 -1
- package/dist/es/EFSClient.js.map +0 -1
- package/dist/es/commands/CreateAccessPointCommand.js.map +0 -1
- package/dist/es/commands/CreateFileSystemCommand.js +0 -118
- package/dist/es/commands/CreateFileSystemCommand.js.map +0 -1
- package/dist/es/commands/CreateMountTargetCommand.js +0 -206
- package/dist/es/commands/CreateMountTargetCommand.js.map +0 -1
- package/dist/es/commands/CreateTagsCommand.js.map +0 -1
- package/dist/es/commands/DeleteAccessPointCommand.js.map +0 -1
- package/dist/es/commands/DeleteFileSystemCommand.js +0 -79
- package/dist/es/commands/DeleteFileSystemCommand.js.map +0 -1
- package/dist/es/commands/DeleteFileSystemPolicyCommand.js.map +0 -1
- package/dist/es/commands/DeleteMountTargetCommand.js +0 -98
- package/dist/es/commands/DeleteMountTargetCommand.js.map +0 -1
- package/dist/es/commands/DeleteTagsCommand.js +0 -77
- package/dist/es/commands/DeleteTagsCommand.js.map +0 -1
- package/dist/es/commands/DescribeAccessPointsCommand.js.map +0 -1
- package/dist/es/commands/DescribeAccountPreferencesCommand.js.map +0 -1
- package/dist/es/commands/DescribeBackupPolicyCommand.js.map +0 -1
- package/dist/es/commands/DescribeFileSystemPolicyCommand.js.map +0 -1
- package/dist/es/commands/DescribeFileSystemsCommand.js +0 -87
- package/dist/es/commands/DescribeFileSystemsCommand.js.map +0 -1
- package/dist/es/commands/DescribeLifecycleConfigurationCommand.js.map +0 -1
- package/dist/es/commands/DescribeMountTargetSecurityGroupsCommand.js.map +0 -1
- package/dist/es/commands/DescribeMountTargetsCommand.js.map +0 -1
- package/dist/es/commands/DescribeTagsCommand.js.map +0 -1
- package/dist/es/commands/ListTagsForResourceCommand.js.map +0 -1
- package/dist/es/commands/ModifyMountTargetSecurityGroupsCommand.js +0 -84
- package/dist/es/commands/ModifyMountTargetSecurityGroupsCommand.js.map +0 -1
- package/dist/es/commands/PutAccountPreferencesCommand.js.map +0 -1
- package/dist/es/commands/PutBackupPolicyCommand.js.map +0 -1
- package/dist/es/commands/PutFileSystemPolicyCommand.js +0 -74
- package/dist/es/commands/PutFileSystemPolicyCommand.js.map +0 -1
- package/dist/es/commands/PutLifecycleConfigurationCommand.js +0 -95
- package/dist/es/commands/PutLifecycleConfigurationCommand.js.map +0 -1
- package/dist/es/commands/TagResourceCommand.js.map +0 -1
- package/dist/es/commands/UntagResourceCommand.js.map +0 -1
- package/dist/es/commands/UpdateFileSystemCommand.js.map +0 -1
- package/dist/es/endpoints.js.map +0 -1
- package/dist/es/index.js +0 -36
- package/dist/es/index.js.map +0 -1
- package/dist/es/models/index.js +0 -2
- package/dist/es/models/index.js.map +0 -1
- package/dist/es/models/models_0.js.map +0 -1
- package/dist/es/package.json +0 -93
- package/dist/es/pagination/DescribeAccessPointsPaginator.js.map +0 -1
- package/dist/es/pagination/DescribeFileSystemsPaginator.js.map +0 -1
- package/dist/es/pagination/DescribeTagsPaginator.js.map +0 -1
- package/dist/es/pagination/Interfaces.js +0 -2
- package/dist/es/pagination/Interfaces.js.map +0 -1
- package/dist/es/pagination/ListTagsForResourcePaginator.js.map +0 -1
- package/dist/es/protocols/Aws_restJson1.js.map +0 -1
- package/dist/es/runtimeConfig.browser.js.map +0 -1
- package/dist/es/runtimeConfig.js.map +0 -1
- package/dist/es/runtimeConfig.native.js.map +0 -1
- package/dist/es/runtimeConfig.shared.js.map +0 -1
- package/endpoints.ts +0 -183
- package/jest.config.js +0 -4
- package/models/models_0.ts +0 -2185
- package/pagination/DescribeAccessPointsPaginator.ts +0 -58
- package/pagination/DescribeFileSystemsPaginator.ts +0 -58
- package/pagination/DescribeTagsPaginator.ts +0 -58
- package/pagination/Interfaces.ts +0 -7
- package/pagination/ListTagsForResourcePaginator.ts +0 -58
- package/protocols/Aws_restJson1.ts +0 -4417
- package/runtimeConfig.browser.ts +0 -40
- package/runtimeConfig.native.ts +0 -16
- package/runtimeConfig.shared.ts +0 -16
- package/runtimeConfig.ts +0 -45
- package/tsconfig.es.json +0 -12
- package/tsconfig.json +0 -32
|
@@ -1,4417 +0,0 @@
|
|
|
1
|
-
import { CreateAccessPointCommandInput, CreateAccessPointCommandOutput } from "../commands/CreateAccessPointCommand";
|
|
2
|
-
import { CreateFileSystemCommandInput, CreateFileSystemCommandOutput } from "../commands/CreateFileSystemCommand";
|
|
3
|
-
import { CreateMountTargetCommandInput, CreateMountTargetCommandOutput } from "../commands/CreateMountTargetCommand";
|
|
4
|
-
import { CreateTagsCommandInput, CreateTagsCommandOutput } from "../commands/CreateTagsCommand";
|
|
5
|
-
import { DeleteAccessPointCommandInput, DeleteAccessPointCommandOutput } from "../commands/DeleteAccessPointCommand";
|
|
6
|
-
import { DeleteFileSystemCommandInput, DeleteFileSystemCommandOutput } from "../commands/DeleteFileSystemCommand";
|
|
7
|
-
import {
|
|
8
|
-
DeleteFileSystemPolicyCommandInput,
|
|
9
|
-
DeleteFileSystemPolicyCommandOutput,
|
|
10
|
-
} from "../commands/DeleteFileSystemPolicyCommand";
|
|
11
|
-
import { DeleteMountTargetCommandInput, DeleteMountTargetCommandOutput } from "../commands/DeleteMountTargetCommand";
|
|
12
|
-
import { DeleteTagsCommandInput, DeleteTagsCommandOutput } from "../commands/DeleteTagsCommand";
|
|
13
|
-
import {
|
|
14
|
-
DescribeAccessPointsCommandInput,
|
|
15
|
-
DescribeAccessPointsCommandOutput,
|
|
16
|
-
} from "../commands/DescribeAccessPointsCommand";
|
|
17
|
-
import {
|
|
18
|
-
DescribeAccountPreferencesCommandInput,
|
|
19
|
-
DescribeAccountPreferencesCommandOutput,
|
|
20
|
-
} from "../commands/DescribeAccountPreferencesCommand";
|
|
21
|
-
import {
|
|
22
|
-
DescribeBackupPolicyCommandInput,
|
|
23
|
-
DescribeBackupPolicyCommandOutput,
|
|
24
|
-
} from "../commands/DescribeBackupPolicyCommand";
|
|
25
|
-
import {
|
|
26
|
-
DescribeFileSystemPolicyCommandInput,
|
|
27
|
-
DescribeFileSystemPolicyCommandOutput,
|
|
28
|
-
} from "../commands/DescribeFileSystemPolicyCommand";
|
|
29
|
-
import {
|
|
30
|
-
DescribeFileSystemsCommandInput,
|
|
31
|
-
DescribeFileSystemsCommandOutput,
|
|
32
|
-
} from "../commands/DescribeFileSystemsCommand";
|
|
33
|
-
import {
|
|
34
|
-
DescribeLifecycleConfigurationCommandInput,
|
|
35
|
-
DescribeLifecycleConfigurationCommandOutput,
|
|
36
|
-
} from "../commands/DescribeLifecycleConfigurationCommand";
|
|
37
|
-
import {
|
|
38
|
-
DescribeMountTargetSecurityGroupsCommandInput,
|
|
39
|
-
DescribeMountTargetSecurityGroupsCommandOutput,
|
|
40
|
-
} from "../commands/DescribeMountTargetSecurityGroupsCommand";
|
|
41
|
-
import {
|
|
42
|
-
DescribeMountTargetsCommandInput,
|
|
43
|
-
DescribeMountTargetsCommandOutput,
|
|
44
|
-
} from "../commands/DescribeMountTargetsCommand";
|
|
45
|
-
import { DescribeTagsCommandInput, DescribeTagsCommandOutput } from "../commands/DescribeTagsCommand";
|
|
46
|
-
import {
|
|
47
|
-
ListTagsForResourceCommandInput,
|
|
48
|
-
ListTagsForResourceCommandOutput,
|
|
49
|
-
} from "../commands/ListTagsForResourceCommand";
|
|
50
|
-
import {
|
|
51
|
-
ModifyMountTargetSecurityGroupsCommandInput,
|
|
52
|
-
ModifyMountTargetSecurityGroupsCommandOutput,
|
|
53
|
-
} from "../commands/ModifyMountTargetSecurityGroupsCommand";
|
|
54
|
-
import {
|
|
55
|
-
PutAccountPreferencesCommandInput,
|
|
56
|
-
PutAccountPreferencesCommandOutput,
|
|
57
|
-
} from "../commands/PutAccountPreferencesCommand";
|
|
58
|
-
import { PutBackupPolicyCommandInput, PutBackupPolicyCommandOutput } from "../commands/PutBackupPolicyCommand";
|
|
59
|
-
import {
|
|
60
|
-
PutFileSystemPolicyCommandInput,
|
|
61
|
-
PutFileSystemPolicyCommandOutput,
|
|
62
|
-
} from "../commands/PutFileSystemPolicyCommand";
|
|
63
|
-
import {
|
|
64
|
-
PutLifecycleConfigurationCommandInput,
|
|
65
|
-
PutLifecycleConfigurationCommandOutput,
|
|
66
|
-
} from "../commands/PutLifecycleConfigurationCommand";
|
|
67
|
-
import { TagResourceCommandInput, TagResourceCommandOutput } from "../commands/TagResourceCommand";
|
|
68
|
-
import { UntagResourceCommandInput, UntagResourceCommandOutput } from "../commands/UntagResourceCommand";
|
|
69
|
-
import { UpdateFileSystemCommandInput, UpdateFileSystemCommandOutput } from "../commands/UpdateFileSystemCommand";
|
|
70
|
-
import {
|
|
71
|
-
AccessPointAlreadyExists,
|
|
72
|
-
AccessPointDescription,
|
|
73
|
-
AccessPointLimitExceeded,
|
|
74
|
-
AccessPointNotFound,
|
|
75
|
-
AvailabilityZonesMismatch,
|
|
76
|
-
BackupPolicy,
|
|
77
|
-
BadRequest,
|
|
78
|
-
CreationInfo,
|
|
79
|
-
DependencyTimeout,
|
|
80
|
-
FileSystemAlreadyExists,
|
|
81
|
-
FileSystemDescription,
|
|
82
|
-
FileSystemInUse,
|
|
83
|
-
FileSystemLimitExceeded,
|
|
84
|
-
FileSystemNotFound,
|
|
85
|
-
FileSystemSize,
|
|
86
|
-
IncorrectFileSystemLifeCycleState,
|
|
87
|
-
IncorrectMountTargetState,
|
|
88
|
-
InsufficientThroughputCapacity,
|
|
89
|
-
InternalServerError,
|
|
90
|
-
InvalidPolicyException,
|
|
91
|
-
IpAddressInUse,
|
|
92
|
-
LifecyclePolicy,
|
|
93
|
-
MountTargetConflict,
|
|
94
|
-
MountTargetDescription,
|
|
95
|
-
MountTargetNotFound,
|
|
96
|
-
NetworkInterfaceLimitExceeded,
|
|
97
|
-
NoFreeAddressesInSubnet,
|
|
98
|
-
PolicyNotFound,
|
|
99
|
-
PosixUser,
|
|
100
|
-
Resource,
|
|
101
|
-
ResourceIdPreference,
|
|
102
|
-
RootDirectory,
|
|
103
|
-
SecurityGroupLimitExceeded,
|
|
104
|
-
SecurityGroupNotFound,
|
|
105
|
-
SubnetNotFound,
|
|
106
|
-
Tag,
|
|
107
|
-
ThroughputLimitExceeded,
|
|
108
|
-
TooManyRequests,
|
|
109
|
-
UnsupportedAvailabilityZone,
|
|
110
|
-
ValidationException,
|
|
111
|
-
} from "../models/models_0";
|
|
112
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
113
|
-
import {
|
|
114
|
-
expectBoolean as __expectBoolean,
|
|
115
|
-
expectInt32 as __expectInt32,
|
|
116
|
-
expectLong as __expectLong,
|
|
117
|
-
expectNonNull as __expectNonNull,
|
|
118
|
-
expectNumber as __expectNumber,
|
|
119
|
-
expectObject as __expectObject,
|
|
120
|
-
expectString as __expectString,
|
|
121
|
-
extendedEncodeURIComponent as __extendedEncodeURIComponent,
|
|
122
|
-
limitedParseDouble as __limitedParseDouble,
|
|
123
|
-
parseEpochTimestamp as __parseEpochTimestamp,
|
|
124
|
-
serializeFloat as __serializeFloat,
|
|
125
|
-
} from "@aws-sdk/smithy-client";
|
|
126
|
-
import {
|
|
127
|
-
Endpoint as __Endpoint,
|
|
128
|
-
MetadataBearer as __MetadataBearer,
|
|
129
|
-
ResponseMetadata as __ResponseMetadata,
|
|
130
|
-
SerdeContext as __SerdeContext,
|
|
131
|
-
SmithyException as __SmithyException,
|
|
132
|
-
} from "@aws-sdk/types";
|
|
133
|
-
import { v4 as generateIdempotencyToken } from "uuid";
|
|
134
|
-
|
|
135
|
-
export const serializeAws_restJson1CreateAccessPointCommand = async (
|
|
136
|
-
input: CreateAccessPointCommandInput,
|
|
137
|
-
context: __SerdeContext
|
|
138
|
-
): Promise<__HttpRequest> => {
|
|
139
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
140
|
-
const headers: any = {
|
|
141
|
-
"content-type": "application/json",
|
|
142
|
-
};
|
|
143
|
-
let resolvedPath =
|
|
144
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/access-points";
|
|
145
|
-
let body: any;
|
|
146
|
-
body = JSON.stringify({
|
|
147
|
-
ClientToken: input.ClientToken ?? generateIdempotencyToken(),
|
|
148
|
-
...(input.FileSystemId !== undefined && input.FileSystemId !== null && { FileSystemId: input.FileSystemId }),
|
|
149
|
-
...(input.PosixUser !== undefined &&
|
|
150
|
-
input.PosixUser !== null && { PosixUser: serializeAws_restJson1PosixUser(input.PosixUser, context) }),
|
|
151
|
-
...(input.RootDirectory !== undefined &&
|
|
152
|
-
input.RootDirectory !== null && {
|
|
153
|
-
RootDirectory: serializeAws_restJson1RootDirectory(input.RootDirectory, context),
|
|
154
|
-
}),
|
|
155
|
-
...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
156
|
-
});
|
|
157
|
-
return new __HttpRequest({
|
|
158
|
-
protocol,
|
|
159
|
-
hostname,
|
|
160
|
-
port,
|
|
161
|
-
method: "POST",
|
|
162
|
-
headers,
|
|
163
|
-
path: resolvedPath,
|
|
164
|
-
body,
|
|
165
|
-
});
|
|
166
|
-
};
|
|
167
|
-
|
|
168
|
-
export const serializeAws_restJson1CreateFileSystemCommand = async (
|
|
169
|
-
input: CreateFileSystemCommandInput,
|
|
170
|
-
context: __SerdeContext
|
|
171
|
-
): Promise<__HttpRequest> => {
|
|
172
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
173
|
-
const headers: any = {
|
|
174
|
-
"content-type": "application/json",
|
|
175
|
-
};
|
|
176
|
-
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/file-systems";
|
|
177
|
-
let body: any;
|
|
178
|
-
body = JSON.stringify({
|
|
179
|
-
...(input.AvailabilityZoneName !== undefined &&
|
|
180
|
-
input.AvailabilityZoneName !== null && { AvailabilityZoneName: input.AvailabilityZoneName }),
|
|
181
|
-
...(input.Backup !== undefined && input.Backup !== null && { Backup: input.Backup }),
|
|
182
|
-
CreationToken: input.CreationToken ?? generateIdempotencyToken(),
|
|
183
|
-
...(input.Encrypted !== undefined && input.Encrypted !== null && { Encrypted: input.Encrypted }),
|
|
184
|
-
...(input.KmsKeyId !== undefined && input.KmsKeyId !== null && { KmsKeyId: input.KmsKeyId }),
|
|
185
|
-
...(input.PerformanceMode !== undefined &&
|
|
186
|
-
input.PerformanceMode !== null && { PerformanceMode: input.PerformanceMode }),
|
|
187
|
-
...(input.ProvisionedThroughputInMibps !== undefined &&
|
|
188
|
-
input.ProvisionedThroughputInMibps !== null && {
|
|
189
|
-
ProvisionedThroughputInMibps: __serializeFloat(input.ProvisionedThroughputInMibps),
|
|
190
|
-
}),
|
|
191
|
-
...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
192
|
-
...(input.ThroughputMode !== undefined &&
|
|
193
|
-
input.ThroughputMode !== null && { ThroughputMode: input.ThroughputMode }),
|
|
194
|
-
});
|
|
195
|
-
return new __HttpRequest({
|
|
196
|
-
protocol,
|
|
197
|
-
hostname,
|
|
198
|
-
port,
|
|
199
|
-
method: "POST",
|
|
200
|
-
headers,
|
|
201
|
-
path: resolvedPath,
|
|
202
|
-
body,
|
|
203
|
-
});
|
|
204
|
-
};
|
|
205
|
-
|
|
206
|
-
export const serializeAws_restJson1CreateMountTargetCommand = async (
|
|
207
|
-
input: CreateMountTargetCommandInput,
|
|
208
|
-
context: __SerdeContext
|
|
209
|
-
): Promise<__HttpRequest> => {
|
|
210
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
211
|
-
const headers: any = {
|
|
212
|
-
"content-type": "application/json",
|
|
213
|
-
};
|
|
214
|
-
let resolvedPath =
|
|
215
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/mount-targets";
|
|
216
|
-
let body: any;
|
|
217
|
-
body = JSON.stringify({
|
|
218
|
-
...(input.FileSystemId !== undefined && input.FileSystemId !== null && { FileSystemId: input.FileSystemId }),
|
|
219
|
-
...(input.IpAddress !== undefined && input.IpAddress !== null && { IpAddress: input.IpAddress }),
|
|
220
|
-
...(input.SecurityGroups !== undefined &&
|
|
221
|
-
input.SecurityGroups !== null && {
|
|
222
|
-
SecurityGroups: serializeAws_restJson1SecurityGroups(input.SecurityGroups, context),
|
|
223
|
-
}),
|
|
224
|
-
...(input.SubnetId !== undefined && input.SubnetId !== null && { SubnetId: input.SubnetId }),
|
|
225
|
-
});
|
|
226
|
-
return new __HttpRequest({
|
|
227
|
-
protocol,
|
|
228
|
-
hostname,
|
|
229
|
-
port,
|
|
230
|
-
method: "POST",
|
|
231
|
-
headers,
|
|
232
|
-
path: resolvedPath,
|
|
233
|
-
body,
|
|
234
|
-
});
|
|
235
|
-
};
|
|
236
|
-
|
|
237
|
-
export const serializeAws_restJson1CreateTagsCommand = async (
|
|
238
|
-
input: CreateTagsCommandInput,
|
|
239
|
-
context: __SerdeContext
|
|
240
|
-
): Promise<__HttpRequest> => {
|
|
241
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
242
|
-
const headers: any = {
|
|
243
|
-
"content-type": "application/json",
|
|
244
|
-
};
|
|
245
|
-
let resolvedPath =
|
|
246
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/create-tags/{FileSystemId}";
|
|
247
|
-
if (input.FileSystemId !== undefined) {
|
|
248
|
-
const labelValue: string = input.FileSystemId;
|
|
249
|
-
if (labelValue.length <= 0) {
|
|
250
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
251
|
-
}
|
|
252
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
253
|
-
} else {
|
|
254
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
255
|
-
}
|
|
256
|
-
let body: any;
|
|
257
|
-
body = JSON.stringify({
|
|
258
|
-
...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
259
|
-
});
|
|
260
|
-
return new __HttpRequest({
|
|
261
|
-
protocol,
|
|
262
|
-
hostname,
|
|
263
|
-
port,
|
|
264
|
-
method: "POST",
|
|
265
|
-
headers,
|
|
266
|
-
path: resolvedPath,
|
|
267
|
-
body,
|
|
268
|
-
});
|
|
269
|
-
};
|
|
270
|
-
|
|
271
|
-
export const serializeAws_restJson1DeleteAccessPointCommand = async (
|
|
272
|
-
input: DeleteAccessPointCommandInput,
|
|
273
|
-
context: __SerdeContext
|
|
274
|
-
): Promise<__HttpRequest> => {
|
|
275
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
276
|
-
const headers: any = {};
|
|
277
|
-
let resolvedPath =
|
|
278
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/access-points/{AccessPointId}";
|
|
279
|
-
if (input.AccessPointId !== undefined) {
|
|
280
|
-
const labelValue: string = input.AccessPointId;
|
|
281
|
-
if (labelValue.length <= 0) {
|
|
282
|
-
throw new Error("Empty value provided for input HTTP label: AccessPointId.");
|
|
283
|
-
}
|
|
284
|
-
resolvedPath = resolvedPath.replace("{AccessPointId}", __extendedEncodeURIComponent(labelValue));
|
|
285
|
-
} else {
|
|
286
|
-
throw new Error("No value provided for input HTTP label: AccessPointId.");
|
|
287
|
-
}
|
|
288
|
-
let body: any;
|
|
289
|
-
return new __HttpRequest({
|
|
290
|
-
protocol,
|
|
291
|
-
hostname,
|
|
292
|
-
port,
|
|
293
|
-
method: "DELETE",
|
|
294
|
-
headers,
|
|
295
|
-
path: resolvedPath,
|
|
296
|
-
body,
|
|
297
|
-
});
|
|
298
|
-
};
|
|
299
|
-
|
|
300
|
-
export const serializeAws_restJson1DeleteFileSystemCommand = async (
|
|
301
|
-
input: DeleteFileSystemCommandInput,
|
|
302
|
-
context: __SerdeContext
|
|
303
|
-
): Promise<__HttpRequest> => {
|
|
304
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
305
|
-
const headers: any = {};
|
|
306
|
-
let resolvedPath =
|
|
307
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/file-systems/{FileSystemId}";
|
|
308
|
-
if (input.FileSystemId !== undefined) {
|
|
309
|
-
const labelValue: string = input.FileSystemId;
|
|
310
|
-
if (labelValue.length <= 0) {
|
|
311
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
312
|
-
}
|
|
313
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
314
|
-
} else {
|
|
315
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
316
|
-
}
|
|
317
|
-
let body: any;
|
|
318
|
-
return new __HttpRequest({
|
|
319
|
-
protocol,
|
|
320
|
-
hostname,
|
|
321
|
-
port,
|
|
322
|
-
method: "DELETE",
|
|
323
|
-
headers,
|
|
324
|
-
path: resolvedPath,
|
|
325
|
-
body,
|
|
326
|
-
});
|
|
327
|
-
};
|
|
328
|
-
|
|
329
|
-
export const serializeAws_restJson1DeleteFileSystemPolicyCommand = async (
|
|
330
|
-
input: DeleteFileSystemPolicyCommandInput,
|
|
331
|
-
context: __SerdeContext
|
|
332
|
-
): Promise<__HttpRequest> => {
|
|
333
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
334
|
-
const headers: any = {};
|
|
335
|
-
let resolvedPath =
|
|
336
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
337
|
-
"/2015-02-01/file-systems/{FileSystemId}/policy";
|
|
338
|
-
if (input.FileSystemId !== undefined) {
|
|
339
|
-
const labelValue: string = input.FileSystemId;
|
|
340
|
-
if (labelValue.length <= 0) {
|
|
341
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
342
|
-
}
|
|
343
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
344
|
-
} else {
|
|
345
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
346
|
-
}
|
|
347
|
-
let body: any;
|
|
348
|
-
return new __HttpRequest({
|
|
349
|
-
protocol,
|
|
350
|
-
hostname,
|
|
351
|
-
port,
|
|
352
|
-
method: "DELETE",
|
|
353
|
-
headers,
|
|
354
|
-
path: resolvedPath,
|
|
355
|
-
body,
|
|
356
|
-
});
|
|
357
|
-
};
|
|
358
|
-
|
|
359
|
-
export const serializeAws_restJson1DeleteMountTargetCommand = async (
|
|
360
|
-
input: DeleteMountTargetCommandInput,
|
|
361
|
-
context: __SerdeContext
|
|
362
|
-
): Promise<__HttpRequest> => {
|
|
363
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
364
|
-
const headers: any = {};
|
|
365
|
-
let resolvedPath =
|
|
366
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/mount-targets/{MountTargetId}";
|
|
367
|
-
if (input.MountTargetId !== undefined) {
|
|
368
|
-
const labelValue: string = input.MountTargetId;
|
|
369
|
-
if (labelValue.length <= 0) {
|
|
370
|
-
throw new Error("Empty value provided for input HTTP label: MountTargetId.");
|
|
371
|
-
}
|
|
372
|
-
resolvedPath = resolvedPath.replace("{MountTargetId}", __extendedEncodeURIComponent(labelValue));
|
|
373
|
-
} else {
|
|
374
|
-
throw new Error("No value provided for input HTTP label: MountTargetId.");
|
|
375
|
-
}
|
|
376
|
-
let body: any;
|
|
377
|
-
return new __HttpRequest({
|
|
378
|
-
protocol,
|
|
379
|
-
hostname,
|
|
380
|
-
port,
|
|
381
|
-
method: "DELETE",
|
|
382
|
-
headers,
|
|
383
|
-
path: resolvedPath,
|
|
384
|
-
body,
|
|
385
|
-
});
|
|
386
|
-
};
|
|
387
|
-
|
|
388
|
-
export const serializeAws_restJson1DeleteTagsCommand = async (
|
|
389
|
-
input: DeleteTagsCommandInput,
|
|
390
|
-
context: __SerdeContext
|
|
391
|
-
): Promise<__HttpRequest> => {
|
|
392
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
393
|
-
const headers: any = {
|
|
394
|
-
"content-type": "application/json",
|
|
395
|
-
};
|
|
396
|
-
let resolvedPath =
|
|
397
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/delete-tags/{FileSystemId}";
|
|
398
|
-
if (input.FileSystemId !== undefined) {
|
|
399
|
-
const labelValue: string = input.FileSystemId;
|
|
400
|
-
if (labelValue.length <= 0) {
|
|
401
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
402
|
-
}
|
|
403
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
404
|
-
} else {
|
|
405
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
406
|
-
}
|
|
407
|
-
let body: any;
|
|
408
|
-
body = JSON.stringify({
|
|
409
|
-
...(input.TagKeys !== undefined &&
|
|
410
|
-
input.TagKeys !== null && { TagKeys: serializeAws_restJson1TagKeys(input.TagKeys, context) }),
|
|
411
|
-
});
|
|
412
|
-
return new __HttpRequest({
|
|
413
|
-
protocol,
|
|
414
|
-
hostname,
|
|
415
|
-
port,
|
|
416
|
-
method: "POST",
|
|
417
|
-
headers,
|
|
418
|
-
path: resolvedPath,
|
|
419
|
-
body,
|
|
420
|
-
});
|
|
421
|
-
};
|
|
422
|
-
|
|
423
|
-
export const serializeAws_restJson1DescribeAccessPointsCommand = async (
|
|
424
|
-
input: DescribeAccessPointsCommandInput,
|
|
425
|
-
context: __SerdeContext
|
|
426
|
-
): Promise<__HttpRequest> => {
|
|
427
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
428
|
-
const headers: any = {};
|
|
429
|
-
let resolvedPath =
|
|
430
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/access-points";
|
|
431
|
-
const query: any = {
|
|
432
|
-
...(input.MaxResults !== undefined && { MaxResults: input.MaxResults.toString() }),
|
|
433
|
-
...(input.NextToken !== undefined && { NextToken: input.NextToken }),
|
|
434
|
-
...(input.AccessPointId !== undefined && { AccessPointId: input.AccessPointId }),
|
|
435
|
-
...(input.FileSystemId !== undefined && { FileSystemId: input.FileSystemId }),
|
|
436
|
-
};
|
|
437
|
-
let body: any;
|
|
438
|
-
return new __HttpRequest({
|
|
439
|
-
protocol,
|
|
440
|
-
hostname,
|
|
441
|
-
port,
|
|
442
|
-
method: "GET",
|
|
443
|
-
headers,
|
|
444
|
-
path: resolvedPath,
|
|
445
|
-
query,
|
|
446
|
-
body,
|
|
447
|
-
});
|
|
448
|
-
};
|
|
449
|
-
|
|
450
|
-
export const serializeAws_restJson1DescribeAccountPreferencesCommand = async (
|
|
451
|
-
input: DescribeAccountPreferencesCommandInput,
|
|
452
|
-
context: __SerdeContext
|
|
453
|
-
): Promise<__HttpRequest> => {
|
|
454
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
455
|
-
const headers: any = {
|
|
456
|
-
"content-type": "application/json",
|
|
457
|
-
};
|
|
458
|
-
let resolvedPath =
|
|
459
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/account-preferences";
|
|
460
|
-
let body: any;
|
|
461
|
-
body = JSON.stringify({
|
|
462
|
-
...(input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults }),
|
|
463
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
464
|
-
});
|
|
465
|
-
return new __HttpRequest({
|
|
466
|
-
protocol,
|
|
467
|
-
hostname,
|
|
468
|
-
port,
|
|
469
|
-
method: "GET",
|
|
470
|
-
headers,
|
|
471
|
-
path: resolvedPath,
|
|
472
|
-
body,
|
|
473
|
-
});
|
|
474
|
-
};
|
|
475
|
-
|
|
476
|
-
export const serializeAws_restJson1DescribeBackupPolicyCommand = async (
|
|
477
|
-
input: DescribeBackupPolicyCommandInput,
|
|
478
|
-
context: __SerdeContext
|
|
479
|
-
): Promise<__HttpRequest> => {
|
|
480
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
481
|
-
const headers: any = {};
|
|
482
|
-
let resolvedPath =
|
|
483
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
484
|
-
"/2015-02-01/file-systems/{FileSystemId}/backup-policy";
|
|
485
|
-
if (input.FileSystemId !== undefined) {
|
|
486
|
-
const labelValue: string = input.FileSystemId;
|
|
487
|
-
if (labelValue.length <= 0) {
|
|
488
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
489
|
-
}
|
|
490
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
491
|
-
} else {
|
|
492
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
493
|
-
}
|
|
494
|
-
let body: any;
|
|
495
|
-
return new __HttpRequest({
|
|
496
|
-
protocol,
|
|
497
|
-
hostname,
|
|
498
|
-
port,
|
|
499
|
-
method: "GET",
|
|
500
|
-
headers,
|
|
501
|
-
path: resolvedPath,
|
|
502
|
-
body,
|
|
503
|
-
});
|
|
504
|
-
};
|
|
505
|
-
|
|
506
|
-
export const serializeAws_restJson1DescribeFileSystemPolicyCommand = async (
|
|
507
|
-
input: DescribeFileSystemPolicyCommandInput,
|
|
508
|
-
context: __SerdeContext
|
|
509
|
-
): Promise<__HttpRequest> => {
|
|
510
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
511
|
-
const headers: any = {};
|
|
512
|
-
let resolvedPath =
|
|
513
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
514
|
-
"/2015-02-01/file-systems/{FileSystemId}/policy";
|
|
515
|
-
if (input.FileSystemId !== undefined) {
|
|
516
|
-
const labelValue: string = input.FileSystemId;
|
|
517
|
-
if (labelValue.length <= 0) {
|
|
518
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
519
|
-
}
|
|
520
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
521
|
-
} else {
|
|
522
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
523
|
-
}
|
|
524
|
-
let body: any;
|
|
525
|
-
return new __HttpRequest({
|
|
526
|
-
protocol,
|
|
527
|
-
hostname,
|
|
528
|
-
port,
|
|
529
|
-
method: "GET",
|
|
530
|
-
headers,
|
|
531
|
-
path: resolvedPath,
|
|
532
|
-
body,
|
|
533
|
-
});
|
|
534
|
-
};
|
|
535
|
-
|
|
536
|
-
export const serializeAws_restJson1DescribeFileSystemsCommand = async (
|
|
537
|
-
input: DescribeFileSystemsCommandInput,
|
|
538
|
-
context: __SerdeContext
|
|
539
|
-
): Promise<__HttpRequest> => {
|
|
540
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
541
|
-
const headers: any = {};
|
|
542
|
-
let resolvedPath = `${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/file-systems";
|
|
543
|
-
const query: any = {
|
|
544
|
-
...(input.MaxItems !== undefined && { MaxItems: input.MaxItems.toString() }),
|
|
545
|
-
...(input.Marker !== undefined && { Marker: input.Marker }),
|
|
546
|
-
...(input.CreationToken !== undefined && { CreationToken: input.CreationToken }),
|
|
547
|
-
...(input.FileSystemId !== undefined && { FileSystemId: input.FileSystemId }),
|
|
548
|
-
};
|
|
549
|
-
let body: any;
|
|
550
|
-
return new __HttpRequest({
|
|
551
|
-
protocol,
|
|
552
|
-
hostname,
|
|
553
|
-
port,
|
|
554
|
-
method: "GET",
|
|
555
|
-
headers,
|
|
556
|
-
path: resolvedPath,
|
|
557
|
-
query,
|
|
558
|
-
body,
|
|
559
|
-
});
|
|
560
|
-
};
|
|
561
|
-
|
|
562
|
-
export const serializeAws_restJson1DescribeLifecycleConfigurationCommand = async (
|
|
563
|
-
input: DescribeLifecycleConfigurationCommandInput,
|
|
564
|
-
context: __SerdeContext
|
|
565
|
-
): Promise<__HttpRequest> => {
|
|
566
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
567
|
-
const headers: any = {};
|
|
568
|
-
let resolvedPath =
|
|
569
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
570
|
-
"/2015-02-01/file-systems/{FileSystemId}/lifecycle-configuration";
|
|
571
|
-
if (input.FileSystemId !== undefined) {
|
|
572
|
-
const labelValue: string = input.FileSystemId;
|
|
573
|
-
if (labelValue.length <= 0) {
|
|
574
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
575
|
-
}
|
|
576
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
577
|
-
} else {
|
|
578
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
579
|
-
}
|
|
580
|
-
let body: any;
|
|
581
|
-
return new __HttpRequest({
|
|
582
|
-
protocol,
|
|
583
|
-
hostname,
|
|
584
|
-
port,
|
|
585
|
-
method: "GET",
|
|
586
|
-
headers,
|
|
587
|
-
path: resolvedPath,
|
|
588
|
-
body,
|
|
589
|
-
});
|
|
590
|
-
};
|
|
591
|
-
|
|
592
|
-
export const serializeAws_restJson1DescribeMountTargetsCommand = async (
|
|
593
|
-
input: DescribeMountTargetsCommandInput,
|
|
594
|
-
context: __SerdeContext
|
|
595
|
-
): Promise<__HttpRequest> => {
|
|
596
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
597
|
-
const headers: any = {};
|
|
598
|
-
let resolvedPath =
|
|
599
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/mount-targets";
|
|
600
|
-
const query: any = {
|
|
601
|
-
...(input.MaxItems !== undefined && { MaxItems: input.MaxItems.toString() }),
|
|
602
|
-
...(input.Marker !== undefined && { Marker: input.Marker }),
|
|
603
|
-
...(input.FileSystemId !== undefined && { FileSystemId: input.FileSystemId }),
|
|
604
|
-
...(input.MountTargetId !== undefined && { MountTargetId: input.MountTargetId }),
|
|
605
|
-
...(input.AccessPointId !== undefined && { AccessPointId: input.AccessPointId }),
|
|
606
|
-
};
|
|
607
|
-
let body: any;
|
|
608
|
-
return new __HttpRequest({
|
|
609
|
-
protocol,
|
|
610
|
-
hostname,
|
|
611
|
-
port,
|
|
612
|
-
method: "GET",
|
|
613
|
-
headers,
|
|
614
|
-
path: resolvedPath,
|
|
615
|
-
query,
|
|
616
|
-
body,
|
|
617
|
-
});
|
|
618
|
-
};
|
|
619
|
-
|
|
620
|
-
export const serializeAws_restJson1DescribeMountTargetSecurityGroupsCommand = async (
|
|
621
|
-
input: DescribeMountTargetSecurityGroupsCommandInput,
|
|
622
|
-
context: __SerdeContext
|
|
623
|
-
): Promise<__HttpRequest> => {
|
|
624
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
625
|
-
const headers: any = {};
|
|
626
|
-
let resolvedPath =
|
|
627
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
628
|
-
"/2015-02-01/mount-targets/{MountTargetId}/security-groups";
|
|
629
|
-
if (input.MountTargetId !== undefined) {
|
|
630
|
-
const labelValue: string = input.MountTargetId;
|
|
631
|
-
if (labelValue.length <= 0) {
|
|
632
|
-
throw new Error("Empty value provided for input HTTP label: MountTargetId.");
|
|
633
|
-
}
|
|
634
|
-
resolvedPath = resolvedPath.replace("{MountTargetId}", __extendedEncodeURIComponent(labelValue));
|
|
635
|
-
} else {
|
|
636
|
-
throw new Error("No value provided for input HTTP label: MountTargetId.");
|
|
637
|
-
}
|
|
638
|
-
let body: any;
|
|
639
|
-
return new __HttpRequest({
|
|
640
|
-
protocol,
|
|
641
|
-
hostname,
|
|
642
|
-
port,
|
|
643
|
-
method: "GET",
|
|
644
|
-
headers,
|
|
645
|
-
path: resolvedPath,
|
|
646
|
-
body,
|
|
647
|
-
});
|
|
648
|
-
};
|
|
649
|
-
|
|
650
|
-
export const serializeAws_restJson1DescribeTagsCommand = async (
|
|
651
|
-
input: DescribeTagsCommandInput,
|
|
652
|
-
context: __SerdeContext
|
|
653
|
-
): Promise<__HttpRequest> => {
|
|
654
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
655
|
-
const headers: any = {};
|
|
656
|
-
let resolvedPath =
|
|
657
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/tags/{FileSystemId}";
|
|
658
|
-
if (input.FileSystemId !== undefined) {
|
|
659
|
-
const labelValue: string = input.FileSystemId;
|
|
660
|
-
if (labelValue.length <= 0) {
|
|
661
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
662
|
-
}
|
|
663
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
664
|
-
} else {
|
|
665
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
666
|
-
}
|
|
667
|
-
const query: any = {
|
|
668
|
-
...(input.MaxItems !== undefined && { MaxItems: input.MaxItems.toString() }),
|
|
669
|
-
...(input.Marker !== undefined && { Marker: input.Marker }),
|
|
670
|
-
};
|
|
671
|
-
let body: any;
|
|
672
|
-
return new __HttpRequest({
|
|
673
|
-
protocol,
|
|
674
|
-
hostname,
|
|
675
|
-
port,
|
|
676
|
-
method: "GET",
|
|
677
|
-
headers,
|
|
678
|
-
path: resolvedPath,
|
|
679
|
-
query,
|
|
680
|
-
body,
|
|
681
|
-
});
|
|
682
|
-
};
|
|
683
|
-
|
|
684
|
-
export const serializeAws_restJson1ListTagsForResourceCommand = async (
|
|
685
|
-
input: ListTagsForResourceCommandInput,
|
|
686
|
-
context: __SerdeContext
|
|
687
|
-
): Promise<__HttpRequest> => {
|
|
688
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
689
|
-
const headers: any = {};
|
|
690
|
-
let resolvedPath =
|
|
691
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/resource-tags/{ResourceId}";
|
|
692
|
-
if (input.ResourceId !== undefined) {
|
|
693
|
-
const labelValue: string = input.ResourceId;
|
|
694
|
-
if (labelValue.length <= 0) {
|
|
695
|
-
throw new Error("Empty value provided for input HTTP label: ResourceId.");
|
|
696
|
-
}
|
|
697
|
-
resolvedPath = resolvedPath.replace("{ResourceId}", __extendedEncodeURIComponent(labelValue));
|
|
698
|
-
} else {
|
|
699
|
-
throw new Error("No value provided for input HTTP label: ResourceId.");
|
|
700
|
-
}
|
|
701
|
-
const query: any = {
|
|
702
|
-
...(input.MaxResults !== undefined && { MaxResults: input.MaxResults.toString() }),
|
|
703
|
-
...(input.NextToken !== undefined && { NextToken: input.NextToken }),
|
|
704
|
-
};
|
|
705
|
-
let body: any;
|
|
706
|
-
return new __HttpRequest({
|
|
707
|
-
protocol,
|
|
708
|
-
hostname,
|
|
709
|
-
port,
|
|
710
|
-
method: "GET",
|
|
711
|
-
headers,
|
|
712
|
-
path: resolvedPath,
|
|
713
|
-
query,
|
|
714
|
-
body,
|
|
715
|
-
});
|
|
716
|
-
};
|
|
717
|
-
|
|
718
|
-
export const serializeAws_restJson1ModifyMountTargetSecurityGroupsCommand = async (
|
|
719
|
-
input: ModifyMountTargetSecurityGroupsCommandInput,
|
|
720
|
-
context: __SerdeContext
|
|
721
|
-
): Promise<__HttpRequest> => {
|
|
722
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
723
|
-
const headers: any = {
|
|
724
|
-
"content-type": "application/json",
|
|
725
|
-
};
|
|
726
|
-
let resolvedPath =
|
|
727
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
728
|
-
"/2015-02-01/mount-targets/{MountTargetId}/security-groups";
|
|
729
|
-
if (input.MountTargetId !== undefined) {
|
|
730
|
-
const labelValue: string = input.MountTargetId;
|
|
731
|
-
if (labelValue.length <= 0) {
|
|
732
|
-
throw new Error("Empty value provided for input HTTP label: MountTargetId.");
|
|
733
|
-
}
|
|
734
|
-
resolvedPath = resolvedPath.replace("{MountTargetId}", __extendedEncodeURIComponent(labelValue));
|
|
735
|
-
} else {
|
|
736
|
-
throw new Error("No value provided for input HTTP label: MountTargetId.");
|
|
737
|
-
}
|
|
738
|
-
let body: any;
|
|
739
|
-
body = JSON.stringify({
|
|
740
|
-
...(input.SecurityGroups !== undefined &&
|
|
741
|
-
input.SecurityGroups !== null && {
|
|
742
|
-
SecurityGroups: serializeAws_restJson1SecurityGroups(input.SecurityGroups, context),
|
|
743
|
-
}),
|
|
744
|
-
});
|
|
745
|
-
return new __HttpRequest({
|
|
746
|
-
protocol,
|
|
747
|
-
hostname,
|
|
748
|
-
port,
|
|
749
|
-
method: "PUT",
|
|
750
|
-
headers,
|
|
751
|
-
path: resolvedPath,
|
|
752
|
-
body,
|
|
753
|
-
});
|
|
754
|
-
};
|
|
755
|
-
|
|
756
|
-
export const serializeAws_restJson1PutAccountPreferencesCommand = async (
|
|
757
|
-
input: PutAccountPreferencesCommandInput,
|
|
758
|
-
context: __SerdeContext
|
|
759
|
-
): Promise<__HttpRequest> => {
|
|
760
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
761
|
-
const headers: any = {
|
|
762
|
-
"content-type": "application/json",
|
|
763
|
-
};
|
|
764
|
-
let resolvedPath =
|
|
765
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/account-preferences";
|
|
766
|
-
let body: any;
|
|
767
|
-
body = JSON.stringify({
|
|
768
|
-
...(input.ResourceIdType !== undefined &&
|
|
769
|
-
input.ResourceIdType !== null && { ResourceIdType: input.ResourceIdType }),
|
|
770
|
-
});
|
|
771
|
-
return new __HttpRequest({
|
|
772
|
-
protocol,
|
|
773
|
-
hostname,
|
|
774
|
-
port,
|
|
775
|
-
method: "PUT",
|
|
776
|
-
headers,
|
|
777
|
-
path: resolvedPath,
|
|
778
|
-
body,
|
|
779
|
-
});
|
|
780
|
-
};
|
|
781
|
-
|
|
782
|
-
export const serializeAws_restJson1PutBackupPolicyCommand = async (
|
|
783
|
-
input: PutBackupPolicyCommandInput,
|
|
784
|
-
context: __SerdeContext
|
|
785
|
-
): Promise<__HttpRequest> => {
|
|
786
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
787
|
-
const headers: any = {
|
|
788
|
-
"content-type": "application/json",
|
|
789
|
-
};
|
|
790
|
-
let resolvedPath =
|
|
791
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
792
|
-
"/2015-02-01/file-systems/{FileSystemId}/backup-policy";
|
|
793
|
-
if (input.FileSystemId !== undefined) {
|
|
794
|
-
const labelValue: string = input.FileSystemId;
|
|
795
|
-
if (labelValue.length <= 0) {
|
|
796
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
797
|
-
}
|
|
798
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
799
|
-
} else {
|
|
800
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
801
|
-
}
|
|
802
|
-
let body: any;
|
|
803
|
-
body = JSON.stringify({
|
|
804
|
-
...(input.BackupPolicy !== undefined &&
|
|
805
|
-
input.BackupPolicy !== null && { BackupPolicy: serializeAws_restJson1BackupPolicy(input.BackupPolicy, context) }),
|
|
806
|
-
});
|
|
807
|
-
return new __HttpRequest({
|
|
808
|
-
protocol,
|
|
809
|
-
hostname,
|
|
810
|
-
port,
|
|
811
|
-
method: "PUT",
|
|
812
|
-
headers,
|
|
813
|
-
path: resolvedPath,
|
|
814
|
-
body,
|
|
815
|
-
});
|
|
816
|
-
};
|
|
817
|
-
|
|
818
|
-
export const serializeAws_restJson1PutFileSystemPolicyCommand = async (
|
|
819
|
-
input: PutFileSystemPolicyCommandInput,
|
|
820
|
-
context: __SerdeContext
|
|
821
|
-
): Promise<__HttpRequest> => {
|
|
822
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
823
|
-
const headers: any = {
|
|
824
|
-
"content-type": "application/json",
|
|
825
|
-
};
|
|
826
|
-
let resolvedPath =
|
|
827
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
828
|
-
"/2015-02-01/file-systems/{FileSystemId}/policy";
|
|
829
|
-
if (input.FileSystemId !== undefined) {
|
|
830
|
-
const labelValue: string = input.FileSystemId;
|
|
831
|
-
if (labelValue.length <= 0) {
|
|
832
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
833
|
-
}
|
|
834
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
835
|
-
} else {
|
|
836
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
837
|
-
}
|
|
838
|
-
let body: any;
|
|
839
|
-
body = JSON.stringify({
|
|
840
|
-
...(input.BypassPolicyLockoutSafetyCheck !== undefined &&
|
|
841
|
-
input.BypassPolicyLockoutSafetyCheck !== null && {
|
|
842
|
-
BypassPolicyLockoutSafetyCheck: input.BypassPolicyLockoutSafetyCheck,
|
|
843
|
-
}),
|
|
844
|
-
...(input.Policy !== undefined && input.Policy !== null && { Policy: input.Policy }),
|
|
845
|
-
});
|
|
846
|
-
return new __HttpRequest({
|
|
847
|
-
protocol,
|
|
848
|
-
hostname,
|
|
849
|
-
port,
|
|
850
|
-
method: "PUT",
|
|
851
|
-
headers,
|
|
852
|
-
path: resolvedPath,
|
|
853
|
-
body,
|
|
854
|
-
});
|
|
855
|
-
};
|
|
856
|
-
|
|
857
|
-
export const serializeAws_restJson1PutLifecycleConfigurationCommand = async (
|
|
858
|
-
input: PutLifecycleConfigurationCommandInput,
|
|
859
|
-
context: __SerdeContext
|
|
860
|
-
): Promise<__HttpRequest> => {
|
|
861
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
862
|
-
const headers: any = {
|
|
863
|
-
"content-type": "application/json",
|
|
864
|
-
};
|
|
865
|
-
let resolvedPath =
|
|
866
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` +
|
|
867
|
-
"/2015-02-01/file-systems/{FileSystemId}/lifecycle-configuration";
|
|
868
|
-
if (input.FileSystemId !== undefined) {
|
|
869
|
-
const labelValue: string = input.FileSystemId;
|
|
870
|
-
if (labelValue.length <= 0) {
|
|
871
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
872
|
-
}
|
|
873
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
874
|
-
} else {
|
|
875
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
876
|
-
}
|
|
877
|
-
let body: any;
|
|
878
|
-
body = JSON.stringify({
|
|
879
|
-
...(input.LifecyclePolicies !== undefined &&
|
|
880
|
-
input.LifecyclePolicies !== null && {
|
|
881
|
-
LifecyclePolicies: serializeAws_restJson1LifecyclePolicies(input.LifecyclePolicies, context),
|
|
882
|
-
}),
|
|
883
|
-
});
|
|
884
|
-
return new __HttpRequest({
|
|
885
|
-
protocol,
|
|
886
|
-
hostname,
|
|
887
|
-
port,
|
|
888
|
-
method: "PUT",
|
|
889
|
-
headers,
|
|
890
|
-
path: resolvedPath,
|
|
891
|
-
body,
|
|
892
|
-
});
|
|
893
|
-
};
|
|
894
|
-
|
|
895
|
-
export const serializeAws_restJson1TagResourceCommand = async (
|
|
896
|
-
input: TagResourceCommandInput,
|
|
897
|
-
context: __SerdeContext
|
|
898
|
-
): Promise<__HttpRequest> => {
|
|
899
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
900
|
-
const headers: any = {
|
|
901
|
-
"content-type": "application/json",
|
|
902
|
-
};
|
|
903
|
-
let resolvedPath =
|
|
904
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/resource-tags/{ResourceId}";
|
|
905
|
-
if (input.ResourceId !== undefined) {
|
|
906
|
-
const labelValue: string = input.ResourceId;
|
|
907
|
-
if (labelValue.length <= 0) {
|
|
908
|
-
throw new Error("Empty value provided for input HTTP label: ResourceId.");
|
|
909
|
-
}
|
|
910
|
-
resolvedPath = resolvedPath.replace("{ResourceId}", __extendedEncodeURIComponent(labelValue));
|
|
911
|
-
} else {
|
|
912
|
-
throw new Error("No value provided for input HTTP label: ResourceId.");
|
|
913
|
-
}
|
|
914
|
-
let body: any;
|
|
915
|
-
body = JSON.stringify({
|
|
916
|
-
...(input.Tags !== undefined && input.Tags !== null && { Tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
917
|
-
});
|
|
918
|
-
return new __HttpRequest({
|
|
919
|
-
protocol,
|
|
920
|
-
hostname,
|
|
921
|
-
port,
|
|
922
|
-
method: "POST",
|
|
923
|
-
headers,
|
|
924
|
-
path: resolvedPath,
|
|
925
|
-
body,
|
|
926
|
-
});
|
|
927
|
-
};
|
|
928
|
-
|
|
929
|
-
export const serializeAws_restJson1UntagResourceCommand = async (
|
|
930
|
-
input: UntagResourceCommandInput,
|
|
931
|
-
context: __SerdeContext
|
|
932
|
-
): Promise<__HttpRequest> => {
|
|
933
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
934
|
-
const headers: any = {};
|
|
935
|
-
let resolvedPath =
|
|
936
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/resource-tags/{ResourceId}";
|
|
937
|
-
if (input.ResourceId !== undefined) {
|
|
938
|
-
const labelValue: string = input.ResourceId;
|
|
939
|
-
if (labelValue.length <= 0) {
|
|
940
|
-
throw new Error("Empty value provided for input HTTP label: ResourceId.");
|
|
941
|
-
}
|
|
942
|
-
resolvedPath = resolvedPath.replace("{ResourceId}", __extendedEncodeURIComponent(labelValue));
|
|
943
|
-
} else {
|
|
944
|
-
throw new Error("No value provided for input HTTP label: ResourceId.");
|
|
945
|
-
}
|
|
946
|
-
const query: any = {
|
|
947
|
-
...(input.TagKeys !== undefined && { tagKeys: (input.TagKeys || []).map((_entry) => _entry as any) }),
|
|
948
|
-
};
|
|
949
|
-
let body: any;
|
|
950
|
-
return new __HttpRequest({
|
|
951
|
-
protocol,
|
|
952
|
-
hostname,
|
|
953
|
-
port,
|
|
954
|
-
method: "DELETE",
|
|
955
|
-
headers,
|
|
956
|
-
path: resolvedPath,
|
|
957
|
-
query,
|
|
958
|
-
body,
|
|
959
|
-
});
|
|
960
|
-
};
|
|
961
|
-
|
|
962
|
-
export const serializeAws_restJson1UpdateFileSystemCommand = async (
|
|
963
|
-
input: UpdateFileSystemCommandInput,
|
|
964
|
-
context: __SerdeContext
|
|
965
|
-
): Promise<__HttpRequest> => {
|
|
966
|
-
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
967
|
-
const headers: any = {
|
|
968
|
-
"content-type": "application/json",
|
|
969
|
-
};
|
|
970
|
-
let resolvedPath =
|
|
971
|
-
`${basePath?.endsWith("/") ? basePath.slice(0, -1) : basePath || ""}` + "/2015-02-01/file-systems/{FileSystemId}";
|
|
972
|
-
if (input.FileSystemId !== undefined) {
|
|
973
|
-
const labelValue: string = input.FileSystemId;
|
|
974
|
-
if (labelValue.length <= 0) {
|
|
975
|
-
throw new Error("Empty value provided for input HTTP label: FileSystemId.");
|
|
976
|
-
}
|
|
977
|
-
resolvedPath = resolvedPath.replace("{FileSystemId}", __extendedEncodeURIComponent(labelValue));
|
|
978
|
-
} else {
|
|
979
|
-
throw new Error("No value provided for input HTTP label: FileSystemId.");
|
|
980
|
-
}
|
|
981
|
-
let body: any;
|
|
982
|
-
body = JSON.stringify({
|
|
983
|
-
...(input.ProvisionedThroughputInMibps !== undefined &&
|
|
984
|
-
input.ProvisionedThroughputInMibps !== null && {
|
|
985
|
-
ProvisionedThroughputInMibps: __serializeFloat(input.ProvisionedThroughputInMibps),
|
|
986
|
-
}),
|
|
987
|
-
...(input.ThroughputMode !== undefined &&
|
|
988
|
-
input.ThroughputMode !== null && { ThroughputMode: input.ThroughputMode }),
|
|
989
|
-
});
|
|
990
|
-
return new __HttpRequest({
|
|
991
|
-
protocol,
|
|
992
|
-
hostname,
|
|
993
|
-
port,
|
|
994
|
-
method: "PUT",
|
|
995
|
-
headers,
|
|
996
|
-
path: resolvedPath,
|
|
997
|
-
body,
|
|
998
|
-
});
|
|
999
|
-
};
|
|
1000
|
-
|
|
1001
|
-
export const deserializeAws_restJson1CreateAccessPointCommand = async (
|
|
1002
|
-
output: __HttpResponse,
|
|
1003
|
-
context: __SerdeContext
|
|
1004
|
-
): Promise<CreateAccessPointCommandOutput> => {
|
|
1005
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1006
|
-
return deserializeAws_restJson1CreateAccessPointCommandError(output, context);
|
|
1007
|
-
}
|
|
1008
|
-
const contents: CreateAccessPointCommandOutput = {
|
|
1009
|
-
$metadata: deserializeMetadata(output),
|
|
1010
|
-
AccessPointArn: undefined,
|
|
1011
|
-
AccessPointId: undefined,
|
|
1012
|
-
ClientToken: undefined,
|
|
1013
|
-
FileSystemId: undefined,
|
|
1014
|
-
LifeCycleState: undefined,
|
|
1015
|
-
Name: undefined,
|
|
1016
|
-
OwnerId: undefined,
|
|
1017
|
-
PosixUser: undefined,
|
|
1018
|
-
RootDirectory: undefined,
|
|
1019
|
-
Tags: undefined,
|
|
1020
|
-
};
|
|
1021
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1022
|
-
if (data.AccessPointArn !== undefined && data.AccessPointArn !== null) {
|
|
1023
|
-
contents.AccessPointArn = __expectString(data.AccessPointArn);
|
|
1024
|
-
}
|
|
1025
|
-
if (data.AccessPointId !== undefined && data.AccessPointId !== null) {
|
|
1026
|
-
contents.AccessPointId = __expectString(data.AccessPointId);
|
|
1027
|
-
}
|
|
1028
|
-
if (data.ClientToken !== undefined && data.ClientToken !== null) {
|
|
1029
|
-
contents.ClientToken = __expectString(data.ClientToken);
|
|
1030
|
-
}
|
|
1031
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
1032
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
1033
|
-
}
|
|
1034
|
-
if (data.LifeCycleState !== undefined && data.LifeCycleState !== null) {
|
|
1035
|
-
contents.LifeCycleState = __expectString(data.LifeCycleState);
|
|
1036
|
-
}
|
|
1037
|
-
if (data.Name !== undefined && data.Name !== null) {
|
|
1038
|
-
contents.Name = __expectString(data.Name);
|
|
1039
|
-
}
|
|
1040
|
-
if (data.OwnerId !== undefined && data.OwnerId !== null) {
|
|
1041
|
-
contents.OwnerId = __expectString(data.OwnerId);
|
|
1042
|
-
}
|
|
1043
|
-
if (data.PosixUser !== undefined && data.PosixUser !== null) {
|
|
1044
|
-
contents.PosixUser = deserializeAws_restJson1PosixUser(data.PosixUser, context);
|
|
1045
|
-
}
|
|
1046
|
-
if (data.RootDirectory !== undefined && data.RootDirectory !== null) {
|
|
1047
|
-
contents.RootDirectory = deserializeAws_restJson1RootDirectory(data.RootDirectory, context);
|
|
1048
|
-
}
|
|
1049
|
-
if (data.Tags !== undefined && data.Tags !== null) {
|
|
1050
|
-
contents.Tags = deserializeAws_restJson1Tags(data.Tags, context);
|
|
1051
|
-
}
|
|
1052
|
-
return Promise.resolve(contents);
|
|
1053
|
-
};
|
|
1054
|
-
|
|
1055
|
-
const deserializeAws_restJson1CreateAccessPointCommandError = async (
|
|
1056
|
-
output: __HttpResponse,
|
|
1057
|
-
context: __SerdeContext
|
|
1058
|
-
): Promise<CreateAccessPointCommandOutput> => {
|
|
1059
|
-
const parsedOutput: any = {
|
|
1060
|
-
...output,
|
|
1061
|
-
body: await parseBody(output.body, context),
|
|
1062
|
-
};
|
|
1063
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1064
|
-
let errorCode: string = "UnknownError";
|
|
1065
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1066
|
-
switch (errorCode) {
|
|
1067
|
-
case "AccessPointAlreadyExists":
|
|
1068
|
-
case "com.amazonaws.efs#AccessPointAlreadyExists":
|
|
1069
|
-
response = {
|
|
1070
|
-
...(await deserializeAws_restJson1AccessPointAlreadyExistsResponse(parsedOutput, context)),
|
|
1071
|
-
name: errorCode,
|
|
1072
|
-
$metadata: deserializeMetadata(output),
|
|
1073
|
-
};
|
|
1074
|
-
break;
|
|
1075
|
-
case "AccessPointLimitExceeded":
|
|
1076
|
-
case "com.amazonaws.efs#AccessPointLimitExceeded":
|
|
1077
|
-
response = {
|
|
1078
|
-
...(await deserializeAws_restJson1AccessPointLimitExceededResponse(parsedOutput, context)),
|
|
1079
|
-
name: errorCode,
|
|
1080
|
-
$metadata: deserializeMetadata(output),
|
|
1081
|
-
};
|
|
1082
|
-
break;
|
|
1083
|
-
case "BadRequest":
|
|
1084
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1085
|
-
response = {
|
|
1086
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1087
|
-
name: errorCode,
|
|
1088
|
-
$metadata: deserializeMetadata(output),
|
|
1089
|
-
};
|
|
1090
|
-
break;
|
|
1091
|
-
case "FileSystemNotFound":
|
|
1092
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1093
|
-
response = {
|
|
1094
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1095
|
-
name: errorCode,
|
|
1096
|
-
$metadata: deserializeMetadata(output),
|
|
1097
|
-
};
|
|
1098
|
-
break;
|
|
1099
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
1100
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
1101
|
-
response = {
|
|
1102
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
1103
|
-
name: errorCode,
|
|
1104
|
-
$metadata: deserializeMetadata(output),
|
|
1105
|
-
};
|
|
1106
|
-
break;
|
|
1107
|
-
case "InternalServerError":
|
|
1108
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1109
|
-
response = {
|
|
1110
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1111
|
-
name: errorCode,
|
|
1112
|
-
$metadata: deserializeMetadata(output),
|
|
1113
|
-
};
|
|
1114
|
-
break;
|
|
1115
|
-
default:
|
|
1116
|
-
const parsedBody = parsedOutput.body;
|
|
1117
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1118
|
-
response = {
|
|
1119
|
-
...parsedBody,
|
|
1120
|
-
name: `${errorCode}`,
|
|
1121
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1122
|
-
$fault: "client",
|
|
1123
|
-
$metadata: deserializeMetadata(output),
|
|
1124
|
-
} as any;
|
|
1125
|
-
}
|
|
1126
|
-
const message = response.message || response.Message || errorCode;
|
|
1127
|
-
response.message = message;
|
|
1128
|
-
delete response.Message;
|
|
1129
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1130
|
-
};
|
|
1131
|
-
|
|
1132
|
-
export const deserializeAws_restJson1CreateFileSystemCommand = async (
|
|
1133
|
-
output: __HttpResponse,
|
|
1134
|
-
context: __SerdeContext
|
|
1135
|
-
): Promise<CreateFileSystemCommandOutput> => {
|
|
1136
|
-
if (output.statusCode !== 201 && output.statusCode >= 300) {
|
|
1137
|
-
return deserializeAws_restJson1CreateFileSystemCommandError(output, context);
|
|
1138
|
-
}
|
|
1139
|
-
const contents: CreateFileSystemCommandOutput = {
|
|
1140
|
-
$metadata: deserializeMetadata(output),
|
|
1141
|
-
AvailabilityZoneId: undefined,
|
|
1142
|
-
AvailabilityZoneName: undefined,
|
|
1143
|
-
CreationTime: undefined,
|
|
1144
|
-
CreationToken: undefined,
|
|
1145
|
-
Encrypted: undefined,
|
|
1146
|
-
FileSystemArn: undefined,
|
|
1147
|
-
FileSystemId: undefined,
|
|
1148
|
-
KmsKeyId: undefined,
|
|
1149
|
-
LifeCycleState: undefined,
|
|
1150
|
-
Name: undefined,
|
|
1151
|
-
NumberOfMountTargets: undefined,
|
|
1152
|
-
OwnerId: undefined,
|
|
1153
|
-
PerformanceMode: undefined,
|
|
1154
|
-
ProvisionedThroughputInMibps: undefined,
|
|
1155
|
-
SizeInBytes: undefined,
|
|
1156
|
-
Tags: undefined,
|
|
1157
|
-
ThroughputMode: undefined,
|
|
1158
|
-
};
|
|
1159
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1160
|
-
if (data.AvailabilityZoneId !== undefined && data.AvailabilityZoneId !== null) {
|
|
1161
|
-
contents.AvailabilityZoneId = __expectString(data.AvailabilityZoneId);
|
|
1162
|
-
}
|
|
1163
|
-
if (data.AvailabilityZoneName !== undefined && data.AvailabilityZoneName !== null) {
|
|
1164
|
-
contents.AvailabilityZoneName = __expectString(data.AvailabilityZoneName);
|
|
1165
|
-
}
|
|
1166
|
-
if (data.CreationTime !== undefined && data.CreationTime !== null) {
|
|
1167
|
-
contents.CreationTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.CreationTime)));
|
|
1168
|
-
}
|
|
1169
|
-
if (data.CreationToken !== undefined && data.CreationToken !== null) {
|
|
1170
|
-
contents.CreationToken = __expectString(data.CreationToken);
|
|
1171
|
-
}
|
|
1172
|
-
if (data.Encrypted !== undefined && data.Encrypted !== null) {
|
|
1173
|
-
contents.Encrypted = __expectBoolean(data.Encrypted);
|
|
1174
|
-
}
|
|
1175
|
-
if (data.FileSystemArn !== undefined && data.FileSystemArn !== null) {
|
|
1176
|
-
contents.FileSystemArn = __expectString(data.FileSystemArn);
|
|
1177
|
-
}
|
|
1178
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
1179
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
1180
|
-
}
|
|
1181
|
-
if (data.KmsKeyId !== undefined && data.KmsKeyId !== null) {
|
|
1182
|
-
contents.KmsKeyId = __expectString(data.KmsKeyId);
|
|
1183
|
-
}
|
|
1184
|
-
if (data.LifeCycleState !== undefined && data.LifeCycleState !== null) {
|
|
1185
|
-
contents.LifeCycleState = __expectString(data.LifeCycleState);
|
|
1186
|
-
}
|
|
1187
|
-
if (data.Name !== undefined && data.Name !== null) {
|
|
1188
|
-
contents.Name = __expectString(data.Name);
|
|
1189
|
-
}
|
|
1190
|
-
if (data.NumberOfMountTargets !== undefined && data.NumberOfMountTargets !== null) {
|
|
1191
|
-
contents.NumberOfMountTargets = __expectInt32(data.NumberOfMountTargets);
|
|
1192
|
-
}
|
|
1193
|
-
if (data.OwnerId !== undefined && data.OwnerId !== null) {
|
|
1194
|
-
contents.OwnerId = __expectString(data.OwnerId);
|
|
1195
|
-
}
|
|
1196
|
-
if (data.PerformanceMode !== undefined && data.PerformanceMode !== null) {
|
|
1197
|
-
contents.PerformanceMode = __expectString(data.PerformanceMode);
|
|
1198
|
-
}
|
|
1199
|
-
if (data.ProvisionedThroughputInMibps !== undefined && data.ProvisionedThroughputInMibps !== null) {
|
|
1200
|
-
contents.ProvisionedThroughputInMibps = __limitedParseDouble(data.ProvisionedThroughputInMibps);
|
|
1201
|
-
}
|
|
1202
|
-
if (data.SizeInBytes !== undefined && data.SizeInBytes !== null) {
|
|
1203
|
-
contents.SizeInBytes = deserializeAws_restJson1FileSystemSize(data.SizeInBytes, context);
|
|
1204
|
-
}
|
|
1205
|
-
if (data.Tags !== undefined && data.Tags !== null) {
|
|
1206
|
-
contents.Tags = deserializeAws_restJson1Tags(data.Tags, context);
|
|
1207
|
-
}
|
|
1208
|
-
if (data.ThroughputMode !== undefined && data.ThroughputMode !== null) {
|
|
1209
|
-
contents.ThroughputMode = __expectString(data.ThroughputMode);
|
|
1210
|
-
}
|
|
1211
|
-
return Promise.resolve(contents);
|
|
1212
|
-
};
|
|
1213
|
-
|
|
1214
|
-
const deserializeAws_restJson1CreateFileSystemCommandError = async (
|
|
1215
|
-
output: __HttpResponse,
|
|
1216
|
-
context: __SerdeContext
|
|
1217
|
-
): Promise<CreateFileSystemCommandOutput> => {
|
|
1218
|
-
const parsedOutput: any = {
|
|
1219
|
-
...output,
|
|
1220
|
-
body: await parseBody(output.body, context),
|
|
1221
|
-
};
|
|
1222
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1223
|
-
let errorCode: string = "UnknownError";
|
|
1224
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1225
|
-
switch (errorCode) {
|
|
1226
|
-
case "BadRequest":
|
|
1227
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1228
|
-
response = {
|
|
1229
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1230
|
-
name: errorCode,
|
|
1231
|
-
$metadata: deserializeMetadata(output),
|
|
1232
|
-
};
|
|
1233
|
-
break;
|
|
1234
|
-
case "FileSystemAlreadyExists":
|
|
1235
|
-
case "com.amazonaws.efs#FileSystemAlreadyExists":
|
|
1236
|
-
response = {
|
|
1237
|
-
...(await deserializeAws_restJson1FileSystemAlreadyExistsResponse(parsedOutput, context)),
|
|
1238
|
-
name: errorCode,
|
|
1239
|
-
$metadata: deserializeMetadata(output),
|
|
1240
|
-
};
|
|
1241
|
-
break;
|
|
1242
|
-
case "FileSystemLimitExceeded":
|
|
1243
|
-
case "com.amazonaws.efs#FileSystemLimitExceeded":
|
|
1244
|
-
response = {
|
|
1245
|
-
...(await deserializeAws_restJson1FileSystemLimitExceededResponse(parsedOutput, context)),
|
|
1246
|
-
name: errorCode,
|
|
1247
|
-
$metadata: deserializeMetadata(output),
|
|
1248
|
-
};
|
|
1249
|
-
break;
|
|
1250
|
-
case "InsufficientThroughputCapacity":
|
|
1251
|
-
case "com.amazonaws.efs#InsufficientThroughputCapacity":
|
|
1252
|
-
response = {
|
|
1253
|
-
...(await deserializeAws_restJson1InsufficientThroughputCapacityResponse(parsedOutput, context)),
|
|
1254
|
-
name: errorCode,
|
|
1255
|
-
$metadata: deserializeMetadata(output),
|
|
1256
|
-
};
|
|
1257
|
-
break;
|
|
1258
|
-
case "InternalServerError":
|
|
1259
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1260
|
-
response = {
|
|
1261
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1262
|
-
name: errorCode,
|
|
1263
|
-
$metadata: deserializeMetadata(output),
|
|
1264
|
-
};
|
|
1265
|
-
break;
|
|
1266
|
-
case "ThroughputLimitExceeded":
|
|
1267
|
-
case "com.amazonaws.efs#ThroughputLimitExceeded":
|
|
1268
|
-
response = {
|
|
1269
|
-
...(await deserializeAws_restJson1ThroughputLimitExceededResponse(parsedOutput, context)),
|
|
1270
|
-
name: errorCode,
|
|
1271
|
-
$metadata: deserializeMetadata(output),
|
|
1272
|
-
};
|
|
1273
|
-
break;
|
|
1274
|
-
case "UnsupportedAvailabilityZone":
|
|
1275
|
-
case "com.amazonaws.efs#UnsupportedAvailabilityZone":
|
|
1276
|
-
response = {
|
|
1277
|
-
...(await deserializeAws_restJson1UnsupportedAvailabilityZoneResponse(parsedOutput, context)),
|
|
1278
|
-
name: errorCode,
|
|
1279
|
-
$metadata: deserializeMetadata(output),
|
|
1280
|
-
};
|
|
1281
|
-
break;
|
|
1282
|
-
default:
|
|
1283
|
-
const parsedBody = parsedOutput.body;
|
|
1284
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1285
|
-
response = {
|
|
1286
|
-
...parsedBody,
|
|
1287
|
-
name: `${errorCode}`,
|
|
1288
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1289
|
-
$fault: "client",
|
|
1290
|
-
$metadata: deserializeMetadata(output),
|
|
1291
|
-
} as any;
|
|
1292
|
-
}
|
|
1293
|
-
const message = response.message || response.Message || errorCode;
|
|
1294
|
-
response.message = message;
|
|
1295
|
-
delete response.Message;
|
|
1296
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1297
|
-
};
|
|
1298
|
-
|
|
1299
|
-
export const deserializeAws_restJson1CreateMountTargetCommand = async (
|
|
1300
|
-
output: __HttpResponse,
|
|
1301
|
-
context: __SerdeContext
|
|
1302
|
-
): Promise<CreateMountTargetCommandOutput> => {
|
|
1303
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1304
|
-
return deserializeAws_restJson1CreateMountTargetCommandError(output, context);
|
|
1305
|
-
}
|
|
1306
|
-
const contents: CreateMountTargetCommandOutput = {
|
|
1307
|
-
$metadata: deserializeMetadata(output),
|
|
1308
|
-
AvailabilityZoneId: undefined,
|
|
1309
|
-
AvailabilityZoneName: undefined,
|
|
1310
|
-
FileSystemId: undefined,
|
|
1311
|
-
IpAddress: undefined,
|
|
1312
|
-
LifeCycleState: undefined,
|
|
1313
|
-
MountTargetId: undefined,
|
|
1314
|
-
NetworkInterfaceId: undefined,
|
|
1315
|
-
OwnerId: undefined,
|
|
1316
|
-
SubnetId: undefined,
|
|
1317
|
-
VpcId: undefined,
|
|
1318
|
-
};
|
|
1319
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1320
|
-
if (data.AvailabilityZoneId !== undefined && data.AvailabilityZoneId !== null) {
|
|
1321
|
-
contents.AvailabilityZoneId = __expectString(data.AvailabilityZoneId);
|
|
1322
|
-
}
|
|
1323
|
-
if (data.AvailabilityZoneName !== undefined && data.AvailabilityZoneName !== null) {
|
|
1324
|
-
contents.AvailabilityZoneName = __expectString(data.AvailabilityZoneName);
|
|
1325
|
-
}
|
|
1326
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
1327
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
1328
|
-
}
|
|
1329
|
-
if (data.IpAddress !== undefined && data.IpAddress !== null) {
|
|
1330
|
-
contents.IpAddress = __expectString(data.IpAddress);
|
|
1331
|
-
}
|
|
1332
|
-
if (data.LifeCycleState !== undefined && data.LifeCycleState !== null) {
|
|
1333
|
-
contents.LifeCycleState = __expectString(data.LifeCycleState);
|
|
1334
|
-
}
|
|
1335
|
-
if (data.MountTargetId !== undefined && data.MountTargetId !== null) {
|
|
1336
|
-
contents.MountTargetId = __expectString(data.MountTargetId);
|
|
1337
|
-
}
|
|
1338
|
-
if (data.NetworkInterfaceId !== undefined && data.NetworkInterfaceId !== null) {
|
|
1339
|
-
contents.NetworkInterfaceId = __expectString(data.NetworkInterfaceId);
|
|
1340
|
-
}
|
|
1341
|
-
if (data.OwnerId !== undefined && data.OwnerId !== null) {
|
|
1342
|
-
contents.OwnerId = __expectString(data.OwnerId);
|
|
1343
|
-
}
|
|
1344
|
-
if (data.SubnetId !== undefined && data.SubnetId !== null) {
|
|
1345
|
-
contents.SubnetId = __expectString(data.SubnetId);
|
|
1346
|
-
}
|
|
1347
|
-
if (data.VpcId !== undefined && data.VpcId !== null) {
|
|
1348
|
-
contents.VpcId = __expectString(data.VpcId);
|
|
1349
|
-
}
|
|
1350
|
-
return Promise.resolve(contents);
|
|
1351
|
-
};
|
|
1352
|
-
|
|
1353
|
-
const deserializeAws_restJson1CreateMountTargetCommandError = async (
|
|
1354
|
-
output: __HttpResponse,
|
|
1355
|
-
context: __SerdeContext
|
|
1356
|
-
): Promise<CreateMountTargetCommandOutput> => {
|
|
1357
|
-
const parsedOutput: any = {
|
|
1358
|
-
...output,
|
|
1359
|
-
body: await parseBody(output.body, context),
|
|
1360
|
-
};
|
|
1361
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1362
|
-
let errorCode: string = "UnknownError";
|
|
1363
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1364
|
-
switch (errorCode) {
|
|
1365
|
-
case "AvailabilityZonesMismatch":
|
|
1366
|
-
case "com.amazonaws.efs#AvailabilityZonesMismatch":
|
|
1367
|
-
response = {
|
|
1368
|
-
...(await deserializeAws_restJson1AvailabilityZonesMismatchResponse(parsedOutput, context)),
|
|
1369
|
-
name: errorCode,
|
|
1370
|
-
$metadata: deserializeMetadata(output),
|
|
1371
|
-
};
|
|
1372
|
-
break;
|
|
1373
|
-
case "BadRequest":
|
|
1374
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1375
|
-
response = {
|
|
1376
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1377
|
-
name: errorCode,
|
|
1378
|
-
$metadata: deserializeMetadata(output),
|
|
1379
|
-
};
|
|
1380
|
-
break;
|
|
1381
|
-
case "FileSystemNotFound":
|
|
1382
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1383
|
-
response = {
|
|
1384
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1385
|
-
name: errorCode,
|
|
1386
|
-
$metadata: deserializeMetadata(output),
|
|
1387
|
-
};
|
|
1388
|
-
break;
|
|
1389
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
1390
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
1391
|
-
response = {
|
|
1392
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
1393
|
-
name: errorCode,
|
|
1394
|
-
$metadata: deserializeMetadata(output),
|
|
1395
|
-
};
|
|
1396
|
-
break;
|
|
1397
|
-
case "InternalServerError":
|
|
1398
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1399
|
-
response = {
|
|
1400
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1401
|
-
name: errorCode,
|
|
1402
|
-
$metadata: deserializeMetadata(output),
|
|
1403
|
-
};
|
|
1404
|
-
break;
|
|
1405
|
-
case "IpAddressInUse":
|
|
1406
|
-
case "com.amazonaws.efs#IpAddressInUse":
|
|
1407
|
-
response = {
|
|
1408
|
-
...(await deserializeAws_restJson1IpAddressInUseResponse(parsedOutput, context)),
|
|
1409
|
-
name: errorCode,
|
|
1410
|
-
$metadata: deserializeMetadata(output),
|
|
1411
|
-
};
|
|
1412
|
-
break;
|
|
1413
|
-
case "MountTargetConflict":
|
|
1414
|
-
case "com.amazonaws.efs#MountTargetConflict":
|
|
1415
|
-
response = {
|
|
1416
|
-
...(await deserializeAws_restJson1MountTargetConflictResponse(parsedOutput, context)),
|
|
1417
|
-
name: errorCode,
|
|
1418
|
-
$metadata: deserializeMetadata(output),
|
|
1419
|
-
};
|
|
1420
|
-
break;
|
|
1421
|
-
case "NetworkInterfaceLimitExceeded":
|
|
1422
|
-
case "com.amazonaws.efs#NetworkInterfaceLimitExceeded":
|
|
1423
|
-
response = {
|
|
1424
|
-
...(await deserializeAws_restJson1NetworkInterfaceLimitExceededResponse(parsedOutput, context)),
|
|
1425
|
-
name: errorCode,
|
|
1426
|
-
$metadata: deserializeMetadata(output),
|
|
1427
|
-
};
|
|
1428
|
-
break;
|
|
1429
|
-
case "NoFreeAddressesInSubnet":
|
|
1430
|
-
case "com.amazonaws.efs#NoFreeAddressesInSubnet":
|
|
1431
|
-
response = {
|
|
1432
|
-
...(await deserializeAws_restJson1NoFreeAddressesInSubnetResponse(parsedOutput, context)),
|
|
1433
|
-
name: errorCode,
|
|
1434
|
-
$metadata: deserializeMetadata(output),
|
|
1435
|
-
};
|
|
1436
|
-
break;
|
|
1437
|
-
case "SecurityGroupLimitExceeded":
|
|
1438
|
-
case "com.amazonaws.efs#SecurityGroupLimitExceeded":
|
|
1439
|
-
response = {
|
|
1440
|
-
...(await deserializeAws_restJson1SecurityGroupLimitExceededResponse(parsedOutput, context)),
|
|
1441
|
-
name: errorCode,
|
|
1442
|
-
$metadata: deserializeMetadata(output),
|
|
1443
|
-
};
|
|
1444
|
-
break;
|
|
1445
|
-
case "SecurityGroupNotFound":
|
|
1446
|
-
case "com.amazonaws.efs#SecurityGroupNotFound":
|
|
1447
|
-
response = {
|
|
1448
|
-
...(await deserializeAws_restJson1SecurityGroupNotFoundResponse(parsedOutput, context)),
|
|
1449
|
-
name: errorCode,
|
|
1450
|
-
$metadata: deserializeMetadata(output),
|
|
1451
|
-
};
|
|
1452
|
-
break;
|
|
1453
|
-
case "SubnetNotFound":
|
|
1454
|
-
case "com.amazonaws.efs#SubnetNotFound":
|
|
1455
|
-
response = {
|
|
1456
|
-
...(await deserializeAws_restJson1SubnetNotFoundResponse(parsedOutput, context)),
|
|
1457
|
-
name: errorCode,
|
|
1458
|
-
$metadata: deserializeMetadata(output),
|
|
1459
|
-
};
|
|
1460
|
-
break;
|
|
1461
|
-
case "UnsupportedAvailabilityZone":
|
|
1462
|
-
case "com.amazonaws.efs#UnsupportedAvailabilityZone":
|
|
1463
|
-
response = {
|
|
1464
|
-
...(await deserializeAws_restJson1UnsupportedAvailabilityZoneResponse(parsedOutput, context)),
|
|
1465
|
-
name: errorCode,
|
|
1466
|
-
$metadata: deserializeMetadata(output),
|
|
1467
|
-
};
|
|
1468
|
-
break;
|
|
1469
|
-
default:
|
|
1470
|
-
const parsedBody = parsedOutput.body;
|
|
1471
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1472
|
-
response = {
|
|
1473
|
-
...parsedBody,
|
|
1474
|
-
name: `${errorCode}`,
|
|
1475
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1476
|
-
$fault: "client",
|
|
1477
|
-
$metadata: deserializeMetadata(output),
|
|
1478
|
-
} as any;
|
|
1479
|
-
}
|
|
1480
|
-
const message = response.message || response.Message || errorCode;
|
|
1481
|
-
response.message = message;
|
|
1482
|
-
delete response.Message;
|
|
1483
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1484
|
-
};
|
|
1485
|
-
|
|
1486
|
-
export const deserializeAws_restJson1CreateTagsCommand = async (
|
|
1487
|
-
output: __HttpResponse,
|
|
1488
|
-
context: __SerdeContext
|
|
1489
|
-
): Promise<CreateTagsCommandOutput> => {
|
|
1490
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1491
|
-
return deserializeAws_restJson1CreateTagsCommandError(output, context);
|
|
1492
|
-
}
|
|
1493
|
-
const contents: CreateTagsCommandOutput = {
|
|
1494
|
-
$metadata: deserializeMetadata(output),
|
|
1495
|
-
};
|
|
1496
|
-
await collectBody(output.body, context);
|
|
1497
|
-
return Promise.resolve(contents);
|
|
1498
|
-
};
|
|
1499
|
-
|
|
1500
|
-
const deserializeAws_restJson1CreateTagsCommandError = async (
|
|
1501
|
-
output: __HttpResponse,
|
|
1502
|
-
context: __SerdeContext
|
|
1503
|
-
): Promise<CreateTagsCommandOutput> => {
|
|
1504
|
-
const parsedOutput: any = {
|
|
1505
|
-
...output,
|
|
1506
|
-
body: await parseBody(output.body, context),
|
|
1507
|
-
};
|
|
1508
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1509
|
-
let errorCode: string = "UnknownError";
|
|
1510
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1511
|
-
switch (errorCode) {
|
|
1512
|
-
case "BadRequest":
|
|
1513
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1514
|
-
response = {
|
|
1515
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1516
|
-
name: errorCode,
|
|
1517
|
-
$metadata: deserializeMetadata(output),
|
|
1518
|
-
};
|
|
1519
|
-
break;
|
|
1520
|
-
case "FileSystemNotFound":
|
|
1521
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1522
|
-
response = {
|
|
1523
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1524
|
-
name: errorCode,
|
|
1525
|
-
$metadata: deserializeMetadata(output),
|
|
1526
|
-
};
|
|
1527
|
-
break;
|
|
1528
|
-
case "InternalServerError":
|
|
1529
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1530
|
-
response = {
|
|
1531
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1532
|
-
name: errorCode,
|
|
1533
|
-
$metadata: deserializeMetadata(output),
|
|
1534
|
-
};
|
|
1535
|
-
break;
|
|
1536
|
-
default:
|
|
1537
|
-
const parsedBody = parsedOutput.body;
|
|
1538
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1539
|
-
response = {
|
|
1540
|
-
...parsedBody,
|
|
1541
|
-
name: `${errorCode}`,
|
|
1542
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1543
|
-
$fault: "client",
|
|
1544
|
-
$metadata: deserializeMetadata(output),
|
|
1545
|
-
} as any;
|
|
1546
|
-
}
|
|
1547
|
-
const message = response.message || response.Message || errorCode;
|
|
1548
|
-
response.message = message;
|
|
1549
|
-
delete response.Message;
|
|
1550
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1551
|
-
};
|
|
1552
|
-
|
|
1553
|
-
export const deserializeAws_restJson1DeleteAccessPointCommand = async (
|
|
1554
|
-
output: __HttpResponse,
|
|
1555
|
-
context: __SerdeContext
|
|
1556
|
-
): Promise<DeleteAccessPointCommandOutput> => {
|
|
1557
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1558
|
-
return deserializeAws_restJson1DeleteAccessPointCommandError(output, context);
|
|
1559
|
-
}
|
|
1560
|
-
const contents: DeleteAccessPointCommandOutput = {
|
|
1561
|
-
$metadata: deserializeMetadata(output),
|
|
1562
|
-
};
|
|
1563
|
-
await collectBody(output.body, context);
|
|
1564
|
-
return Promise.resolve(contents);
|
|
1565
|
-
};
|
|
1566
|
-
|
|
1567
|
-
const deserializeAws_restJson1DeleteAccessPointCommandError = async (
|
|
1568
|
-
output: __HttpResponse,
|
|
1569
|
-
context: __SerdeContext
|
|
1570
|
-
): Promise<DeleteAccessPointCommandOutput> => {
|
|
1571
|
-
const parsedOutput: any = {
|
|
1572
|
-
...output,
|
|
1573
|
-
body: await parseBody(output.body, context),
|
|
1574
|
-
};
|
|
1575
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1576
|
-
let errorCode: string = "UnknownError";
|
|
1577
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1578
|
-
switch (errorCode) {
|
|
1579
|
-
case "AccessPointNotFound":
|
|
1580
|
-
case "com.amazonaws.efs#AccessPointNotFound":
|
|
1581
|
-
response = {
|
|
1582
|
-
...(await deserializeAws_restJson1AccessPointNotFoundResponse(parsedOutput, context)),
|
|
1583
|
-
name: errorCode,
|
|
1584
|
-
$metadata: deserializeMetadata(output),
|
|
1585
|
-
};
|
|
1586
|
-
break;
|
|
1587
|
-
case "BadRequest":
|
|
1588
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1589
|
-
response = {
|
|
1590
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1591
|
-
name: errorCode,
|
|
1592
|
-
$metadata: deserializeMetadata(output),
|
|
1593
|
-
};
|
|
1594
|
-
break;
|
|
1595
|
-
case "InternalServerError":
|
|
1596
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1597
|
-
response = {
|
|
1598
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1599
|
-
name: errorCode,
|
|
1600
|
-
$metadata: deserializeMetadata(output),
|
|
1601
|
-
};
|
|
1602
|
-
break;
|
|
1603
|
-
default:
|
|
1604
|
-
const parsedBody = parsedOutput.body;
|
|
1605
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1606
|
-
response = {
|
|
1607
|
-
...parsedBody,
|
|
1608
|
-
name: `${errorCode}`,
|
|
1609
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1610
|
-
$fault: "client",
|
|
1611
|
-
$metadata: deserializeMetadata(output),
|
|
1612
|
-
} as any;
|
|
1613
|
-
}
|
|
1614
|
-
const message = response.message || response.Message || errorCode;
|
|
1615
|
-
response.message = message;
|
|
1616
|
-
delete response.Message;
|
|
1617
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1618
|
-
};
|
|
1619
|
-
|
|
1620
|
-
export const deserializeAws_restJson1DeleteFileSystemCommand = async (
|
|
1621
|
-
output: __HttpResponse,
|
|
1622
|
-
context: __SerdeContext
|
|
1623
|
-
): Promise<DeleteFileSystemCommandOutput> => {
|
|
1624
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1625
|
-
return deserializeAws_restJson1DeleteFileSystemCommandError(output, context);
|
|
1626
|
-
}
|
|
1627
|
-
const contents: DeleteFileSystemCommandOutput = {
|
|
1628
|
-
$metadata: deserializeMetadata(output),
|
|
1629
|
-
};
|
|
1630
|
-
await collectBody(output.body, context);
|
|
1631
|
-
return Promise.resolve(contents);
|
|
1632
|
-
};
|
|
1633
|
-
|
|
1634
|
-
const deserializeAws_restJson1DeleteFileSystemCommandError = async (
|
|
1635
|
-
output: __HttpResponse,
|
|
1636
|
-
context: __SerdeContext
|
|
1637
|
-
): Promise<DeleteFileSystemCommandOutput> => {
|
|
1638
|
-
const parsedOutput: any = {
|
|
1639
|
-
...output,
|
|
1640
|
-
body: await parseBody(output.body, context),
|
|
1641
|
-
};
|
|
1642
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1643
|
-
let errorCode: string = "UnknownError";
|
|
1644
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1645
|
-
switch (errorCode) {
|
|
1646
|
-
case "BadRequest":
|
|
1647
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1648
|
-
response = {
|
|
1649
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1650
|
-
name: errorCode,
|
|
1651
|
-
$metadata: deserializeMetadata(output),
|
|
1652
|
-
};
|
|
1653
|
-
break;
|
|
1654
|
-
case "FileSystemInUse":
|
|
1655
|
-
case "com.amazonaws.efs#FileSystemInUse":
|
|
1656
|
-
response = {
|
|
1657
|
-
...(await deserializeAws_restJson1FileSystemInUseResponse(parsedOutput, context)),
|
|
1658
|
-
name: errorCode,
|
|
1659
|
-
$metadata: deserializeMetadata(output),
|
|
1660
|
-
};
|
|
1661
|
-
break;
|
|
1662
|
-
case "FileSystemNotFound":
|
|
1663
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1664
|
-
response = {
|
|
1665
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1666
|
-
name: errorCode,
|
|
1667
|
-
$metadata: deserializeMetadata(output),
|
|
1668
|
-
};
|
|
1669
|
-
break;
|
|
1670
|
-
case "InternalServerError":
|
|
1671
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1672
|
-
response = {
|
|
1673
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1674
|
-
name: errorCode,
|
|
1675
|
-
$metadata: deserializeMetadata(output),
|
|
1676
|
-
};
|
|
1677
|
-
break;
|
|
1678
|
-
default:
|
|
1679
|
-
const parsedBody = parsedOutput.body;
|
|
1680
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1681
|
-
response = {
|
|
1682
|
-
...parsedBody,
|
|
1683
|
-
name: `${errorCode}`,
|
|
1684
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1685
|
-
$fault: "client",
|
|
1686
|
-
$metadata: deserializeMetadata(output),
|
|
1687
|
-
} as any;
|
|
1688
|
-
}
|
|
1689
|
-
const message = response.message || response.Message || errorCode;
|
|
1690
|
-
response.message = message;
|
|
1691
|
-
delete response.Message;
|
|
1692
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1693
|
-
};
|
|
1694
|
-
|
|
1695
|
-
export const deserializeAws_restJson1DeleteFileSystemPolicyCommand = async (
|
|
1696
|
-
output: __HttpResponse,
|
|
1697
|
-
context: __SerdeContext
|
|
1698
|
-
): Promise<DeleteFileSystemPolicyCommandOutput> => {
|
|
1699
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1700
|
-
return deserializeAws_restJson1DeleteFileSystemPolicyCommandError(output, context);
|
|
1701
|
-
}
|
|
1702
|
-
const contents: DeleteFileSystemPolicyCommandOutput = {
|
|
1703
|
-
$metadata: deserializeMetadata(output),
|
|
1704
|
-
};
|
|
1705
|
-
await collectBody(output.body, context);
|
|
1706
|
-
return Promise.resolve(contents);
|
|
1707
|
-
};
|
|
1708
|
-
|
|
1709
|
-
const deserializeAws_restJson1DeleteFileSystemPolicyCommandError = async (
|
|
1710
|
-
output: __HttpResponse,
|
|
1711
|
-
context: __SerdeContext
|
|
1712
|
-
): Promise<DeleteFileSystemPolicyCommandOutput> => {
|
|
1713
|
-
const parsedOutput: any = {
|
|
1714
|
-
...output,
|
|
1715
|
-
body: await parseBody(output.body, context),
|
|
1716
|
-
};
|
|
1717
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1718
|
-
let errorCode: string = "UnknownError";
|
|
1719
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1720
|
-
switch (errorCode) {
|
|
1721
|
-
case "FileSystemNotFound":
|
|
1722
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1723
|
-
response = {
|
|
1724
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1725
|
-
name: errorCode,
|
|
1726
|
-
$metadata: deserializeMetadata(output),
|
|
1727
|
-
};
|
|
1728
|
-
break;
|
|
1729
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
1730
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
1731
|
-
response = {
|
|
1732
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
1733
|
-
name: errorCode,
|
|
1734
|
-
$metadata: deserializeMetadata(output),
|
|
1735
|
-
};
|
|
1736
|
-
break;
|
|
1737
|
-
case "InternalServerError":
|
|
1738
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1739
|
-
response = {
|
|
1740
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1741
|
-
name: errorCode,
|
|
1742
|
-
$metadata: deserializeMetadata(output),
|
|
1743
|
-
};
|
|
1744
|
-
break;
|
|
1745
|
-
default:
|
|
1746
|
-
const parsedBody = parsedOutput.body;
|
|
1747
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1748
|
-
response = {
|
|
1749
|
-
...parsedBody,
|
|
1750
|
-
name: `${errorCode}`,
|
|
1751
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1752
|
-
$fault: "client",
|
|
1753
|
-
$metadata: deserializeMetadata(output),
|
|
1754
|
-
} as any;
|
|
1755
|
-
}
|
|
1756
|
-
const message = response.message || response.Message || errorCode;
|
|
1757
|
-
response.message = message;
|
|
1758
|
-
delete response.Message;
|
|
1759
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1760
|
-
};
|
|
1761
|
-
|
|
1762
|
-
export const deserializeAws_restJson1DeleteMountTargetCommand = async (
|
|
1763
|
-
output: __HttpResponse,
|
|
1764
|
-
context: __SerdeContext
|
|
1765
|
-
): Promise<DeleteMountTargetCommandOutput> => {
|
|
1766
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1767
|
-
return deserializeAws_restJson1DeleteMountTargetCommandError(output, context);
|
|
1768
|
-
}
|
|
1769
|
-
const contents: DeleteMountTargetCommandOutput = {
|
|
1770
|
-
$metadata: deserializeMetadata(output),
|
|
1771
|
-
};
|
|
1772
|
-
await collectBody(output.body, context);
|
|
1773
|
-
return Promise.resolve(contents);
|
|
1774
|
-
};
|
|
1775
|
-
|
|
1776
|
-
const deserializeAws_restJson1DeleteMountTargetCommandError = async (
|
|
1777
|
-
output: __HttpResponse,
|
|
1778
|
-
context: __SerdeContext
|
|
1779
|
-
): Promise<DeleteMountTargetCommandOutput> => {
|
|
1780
|
-
const parsedOutput: any = {
|
|
1781
|
-
...output,
|
|
1782
|
-
body: await parseBody(output.body, context),
|
|
1783
|
-
};
|
|
1784
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1785
|
-
let errorCode: string = "UnknownError";
|
|
1786
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1787
|
-
switch (errorCode) {
|
|
1788
|
-
case "BadRequest":
|
|
1789
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1790
|
-
response = {
|
|
1791
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1792
|
-
name: errorCode,
|
|
1793
|
-
$metadata: deserializeMetadata(output),
|
|
1794
|
-
};
|
|
1795
|
-
break;
|
|
1796
|
-
case "DependencyTimeout":
|
|
1797
|
-
case "com.amazonaws.efs#DependencyTimeout":
|
|
1798
|
-
response = {
|
|
1799
|
-
...(await deserializeAws_restJson1DependencyTimeoutResponse(parsedOutput, context)),
|
|
1800
|
-
name: errorCode,
|
|
1801
|
-
$metadata: deserializeMetadata(output),
|
|
1802
|
-
};
|
|
1803
|
-
break;
|
|
1804
|
-
case "InternalServerError":
|
|
1805
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1806
|
-
response = {
|
|
1807
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1808
|
-
name: errorCode,
|
|
1809
|
-
$metadata: deserializeMetadata(output),
|
|
1810
|
-
};
|
|
1811
|
-
break;
|
|
1812
|
-
case "MountTargetNotFound":
|
|
1813
|
-
case "com.amazonaws.efs#MountTargetNotFound":
|
|
1814
|
-
response = {
|
|
1815
|
-
...(await deserializeAws_restJson1MountTargetNotFoundResponse(parsedOutput, context)),
|
|
1816
|
-
name: errorCode,
|
|
1817
|
-
$metadata: deserializeMetadata(output),
|
|
1818
|
-
};
|
|
1819
|
-
break;
|
|
1820
|
-
default:
|
|
1821
|
-
const parsedBody = parsedOutput.body;
|
|
1822
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1823
|
-
response = {
|
|
1824
|
-
...parsedBody,
|
|
1825
|
-
name: `${errorCode}`,
|
|
1826
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1827
|
-
$fault: "client",
|
|
1828
|
-
$metadata: deserializeMetadata(output),
|
|
1829
|
-
} as any;
|
|
1830
|
-
}
|
|
1831
|
-
const message = response.message || response.Message || errorCode;
|
|
1832
|
-
response.message = message;
|
|
1833
|
-
delete response.Message;
|
|
1834
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1835
|
-
};
|
|
1836
|
-
|
|
1837
|
-
export const deserializeAws_restJson1DeleteTagsCommand = async (
|
|
1838
|
-
output: __HttpResponse,
|
|
1839
|
-
context: __SerdeContext
|
|
1840
|
-
): Promise<DeleteTagsCommandOutput> => {
|
|
1841
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
1842
|
-
return deserializeAws_restJson1DeleteTagsCommandError(output, context);
|
|
1843
|
-
}
|
|
1844
|
-
const contents: DeleteTagsCommandOutput = {
|
|
1845
|
-
$metadata: deserializeMetadata(output),
|
|
1846
|
-
};
|
|
1847
|
-
await collectBody(output.body, context);
|
|
1848
|
-
return Promise.resolve(contents);
|
|
1849
|
-
};
|
|
1850
|
-
|
|
1851
|
-
const deserializeAws_restJson1DeleteTagsCommandError = async (
|
|
1852
|
-
output: __HttpResponse,
|
|
1853
|
-
context: __SerdeContext
|
|
1854
|
-
): Promise<DeleteTagsCommandOutput> => {
|
|
1855
|
-
const parsedOutput: any = {
|
|
1856
|
-
...output,
|
|
1857
|
-
body: await parseBody(output.body, context),
|
|
1858
|
-
};
|
|
1859
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1860
|
-
let errorCode: string = "UnknownError";
|
|
1861
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1862
|
-
switch (errorCode) {
|
|
1863
|
-
case "BadRequest":
|
|
1864
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1865
|
-
response = {
|
|
1866
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1867
|
-
name: errorCode,
|
|
1868
|
-
$metadata: deserializeMetadata(output),
|
|
1869
|
-
};
|
|
1870
|
-
break;
|
|
1871
|
-
case "FileSystemNotFound":
|
|
1872
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1873
|
-
response = {
|
|
1874
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1875
|
-
name: errorCode,
|
|
1876
|
-
$metadata: deserializeMetadata(output),
|
|
1877
|
-
};
|
|
1878
|
-
break;
|
|
1879
|
-
case "InternalServerError":
|
|
1880
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1881
|
-
response = {
|
|
1882
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1883
|
-
name: errorCode,
|
|
1884
|
-
$metadata: deserializeMetadata(output),
|
|
1885
|
-
};
|
|
1886
|
-
break;
|
|
1887
|
-
default:
|
|
1888
|
-
const parsedBody = parsedOutput.body;
|
|
1889
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1890
|
-
response = {
|
|
1891
|
-
...parsedBody,
|
|
1892
|
-
name: `${errorCode}`,
|
|
1893
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1894
|
-
$fault: "client",
|
|
1895
|
-
$metadata: deserializeMetadata(output),
|
|
1896
|
-
} as any;
|
|
1897
|
-
}
|
|
1898
|
-
const message = response.message || response.Message || errorCode;
|
|
1899
|
-
response.message = message;
|
|
1900
|
-
delete response.Message;
|
|
1901
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1902
|
-
};
|
|
1903
|
-
|
|
1904
|
-
export const deserializeAws_restJson1DescribeAccessPointsCommand = async (
|
|
1905
|
-
output: __HttpResponse,
|
|
1906
|
-
context: __SerdeContext
|
|
1907
|
-
): Promise<DescribeAccessPointsCommandOutput> => {
|
|
1908
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1909
|
-
return deserializeAws_restJson1DescribeAccessPointsCommandError(output, context);
|
|
1910
|
-
}
|
|
1911
|
-
const contents: DescribeAccessPointsCommandOutput = {
|
|
1912
|
-
$metadata: deserializeMetadata(output),
|
|
1913
|
-
AccessPoints: undefined,
|
|
1914
|
-
NextToken: undefined,
|
|
1915
|
-
};
|
|
1916
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
1917
|
-
if (data.AccessPoints !== undefined && data.AccessPoints !== null) {
|
|
1918
|
-
contents.AccessPoints = deserializeAws_restJson1AccessPointDescriptions(data.AccessPoints, context);
|
|
1919
|
-
}
|
|
1920
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1921
|
-
contents.NextToken = __expectString(data.NextToken);
|
|
1922
|
-
}
|
|
1923
|
-
return Promise.resolve(contents);
|
|
1924
|
-
};
|
|
1925
|
-
|
|
1926
|
-
const deserializeAws_restJson1DescribeAccessPointsCommandError = async (
|
|
1927
|
-
output: __HttpResponse,
|
|
1928
|
-
context: __SerdeContext
|
|
1929
|
-
): Promise<DescribeAccessPointsCommandOutput> => {
|
|
1930
|
-
const parsedOutput: any = {
|
|
1931
|
-
...output,
|
|
1932
|
-
body: await parseBody(output.body, context),
|
|
1933
|
-
};
|
|
1934
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
1935
|
-
let errorCode: string = "UnknownError";
|
|
1936
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1937
|
-
switch (errorCode) {
|
|
1938
|
-
case "AccessPointNotFound":
|
|
1939
|
-
case "com.amazonaws.efs#AccessPointNotFound":
|
|
1940
|
-
response = {
|
|
1941
|
-
...(await deserializeAws_restJson1AccessPointNotFoundResponse(parsedOutput, context)),
|
|
1942
|
-
name: errorCode,
|
|
1943
|
-
$metadata: deserializeMetadata(output),
|
|
1944
|
-
};
|
|
1945
|
-
break;
|
|
1946
|
-
case "BadRequest":
|
|
1947
|
-
case "com.amazonaws.efs#BadRequest":
|
|
1948
|
-
response = {
|
|
1949
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
1950
|
-
name: errorCode,
|
|
1951
|
-
$metadata: deserializeMetadata(output),
|
|
1952
|
-
};
|
|
1953
|
-
break;
|
|
1954
|
-
case "FileSystemNotFound":
|
|
1955
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
1956
|
-
response = {
|
|
1957
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
1958
|
-
name: errorCode,
|
|
1959
|
-
$metadata: deserializeMetadata(output),
|
|
1960
|
-
};
|
|
1961
|
-
break;
|
|
1962
|
-
case "InternalServerError":
|
|
1963
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
1964
|
-
response = {
|
|
1965
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
1966
|
-
name: errorCode,
|
|
1967
|
-
$metadata: deserializeMetadata(output),
|
|
1968
|
-
};
|
|
1969
|
-
break;
|
|
1970
|
-
default:
|
|
1971
|
-
const parsedBody = parsedOutput.body;
|
|
1972
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
1973
|
-
response = {
|
|
1974
|
-
...parsedBody,
|
|
1975
|
-
name: `${errorCode}`,
|
|
1976
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
1977
|
-
$fault: "client",
|
|
1978
|
-
$metadata: deserializeMetadata(output),
|
|
1979
|
-
} as any;
|
|
1980
|
-
}
|
|
1981
|
-
const message = response.message || response.Message || errorCode;
|
|
1982
|
-
response.message = message;
|
|
1983
|
-
delete response.Message;
|
|
1984
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
1985
|
-
};
|
|
1986
|
-
|
|
1987
|
-
export const deserializeAws_restJson1DescribeAccountPreferencesCommand = async (
|
|
1988
|
-
output: __HttpResponse,
|
|
1989
|
-
context: __SerdeContext
|
|
1990
|
-
): Promise<DescribeAccountPreferencesCommandOutput> => {
|
|
1991
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1992
|
-
return deserializeAws_restJson1DescribeAccountPreferencesCommandError(output, context);
|
|
1993
|
-
}
|
|
1994
|
-
const contents: DescribeAccountPreferencesCommandOutput = {
|
|
1995
|
-
$metadata: deserializeMetadata(output),
|
|
1996
|
-
NextToken: undefined,
|
|
1997
|
-
ResourceIdPreference: undefined,
|
|
1998
|
-
};
|
|
1999
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2000
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
2001
|
-
contents.NextToken = __expectString(data.NextToken);
|
|
2002
|
-
}
|
|
2003
|
-
if (data.ResourceIdPreference !== undefined && data.ResourceIdPreference !== null) {
|
|
2004
|
-
contents.ResourceIdPreference = deserializeAws_restJson1ResourceIdPreference(data.ResourceIdPreference, context);
|
|
2005
|
-
}
|
|
2006
|
-
return Promise.resolve(contents);
|
|
2007
|
-
};
|
|
2008
|
-
|
|
2009
|
-
const deserializeAws_restJson1DescribeAccountPreferencesCommandError = async (
|
|
2010
|
-
output: __HttpResponse,
|
|
2011
|
-
context: __SerdeContext
|
|
2012
|
-
): Promise<DescribeAccountPreferencesCommandOutput> => {
|
|
2013
|
-
const parsedOutput: any = {
|
|
2014
|
-
...output,
|
|
2015
|
-
body: await parseBody(output.body, context),
|
|
2016
|
-
};
|
|
2017
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2018
|
-
let errorCode: string = "UnknownError";
|
|
2019
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2020
|
-
switch (errorCode) {
|
|
2021
|
-
case "InternalServerError":
|
|
2022
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2023
|
-
response = {
|
|
2024
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2025
|
-
name: errorCode,
|
|
2026
|
-
$metadata: deserializeMetadata(output),
|
|
2027
|
-
};
|
|
2028
|
-
break;
|
|
2029
|
-
default:
|
|
2030
|
-
const parsedBody = parsedOutput.body;
|
|
2031
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2032
|
-
response = {
|
|
2033
|
-
...parsedBody,
|
|
2034
|
-
name: `${errorCode}`,
|
|
2035
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2036
|
-
$fault: "client",
|
|
2037
|
-
$metadata: deserializeMetadata(output),
|
|
2038
|
-
} as any;
|
|
2039
|
-
}
|
|
2040
|
-
const message = response.message || response.Message || errorCode;
|
|
2041
|
-
response.message = message;
|
|
2042
|
-
delete response.Message;
|
|
2043
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2044
|
-
};
|
|
2045
|
-
|
|
2046
|
-
export const deserializeAws_restJson1DescribeBackupPolicyCommand = async (
|
|
2047
|
-
output: __HttpResponse,
|
|
2048
|
-
context: __SerdeContext
|
|
2049
|
-
): Promise<DescribeBackupPolicyCommandOutput> => {
|
|
2050
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2051
|
-
return deserializeAws_restJson1DescribeBackupPolicyCommandError(output, context);
|
|
2052
|
-
}
|
|
2053
|
-
const contents: DescribeBackupPolicyCommandOutput = {
|
|
2054
|
-
$metadata: deserializeMetadata(output),
|
|
2055
|
-
BackupPolicy: undefined,
|
|
2056
|
-
};
|
|
2057
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2058
|
-
if (data.BackupPolicy !== undefined && data.BackupPolicy !== null) {
|
|
2059
|
-
contents.BackupPolicy = deserializeAws_restJson1BackupPolicy(data.BackupPolicy, context);
|
|
2060
|
-
}
|
|
2061
|
-
return Promise.resolve(contents);
|
|
2062
|
-
};
|
|
2063
|
-
|
|
2064
|
-
const deserializeAws_restJson1DescribeBackupPolicyCommandError = async (
|
|
2065
|
-
output: __HttpResponse,
|
|
2066
|
-
context: __SerdeContext
|
|
2067
|
-
): Promise<DescribeBackupPolicyCommandOutput> => {
|
|
2068
|
-
const parsedOutput: any = {
|
|
2069
|
-
...output,
|
|
2070
|
-
body: await parseBody(output.body, context),
|
|
2071
|
-
};
|
|
2072
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2073
|
-
let errorCode: string = "UnknownError";
|
|
2074
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2075
|
-
switch (errorCode) {
|
|
2076
|
-
case "BadRequest":
|
|
2077
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2078
|
-
response = {
|
|
2079
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2080
|
-
name: errorCode,
|
|
2081
|
-
$metadata: deserializeMetadata(output),
|
|
2082
|
-
};
|
|
2083
|
-
break;
|
|
2084
|
-
case "FileSystemNotFound":
|
|
2085
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2086
|
-
response = {
|
|
2087
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2088
|
-
name: errorCode,
|
|
2089
|
-
$metadata: deserializeMetadata(output),
|
|
2090
|
-
};
|
|
2091
|
-
break;
|
|
2092
|
-
case "InternalServerError":
|
|
2093
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2094
|
-
response = {
|
|
2095
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2096
|
-
name: errorCode,
|
|
2097
|
-
$metadata: deserializeMetadata(output),
|
|
2098
|
-
};
|
|
2099
|
-
break;
|
|
2100
|
-
case "PolicyNotFound":
|
|
2101
|
-
case "com.amazonaws.efs#PolicyNotFound":
|
|
2102
|
-
response = {
|
|
2103
|
-
...(await deserializeAws_restJson1PolicyNotFoundResponse(parsedOutput, context)),
|
|
2104
|
-
name: errorCode,
|
|
2105
|
-
$metadata: deserializeMetadata(output),
|
|
2106
|
-
};
|
|
2107
|
-
break;
|
|
2108
|
-
case "ValidationException":
|
|
2109
|
-
case "com.amazonaws.efs#ValidationException":
|
|
2110
|
-
response = {
|
|
2111
|
-
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
2112
|
-
name: errorCode,
|
|
2113
|
-
$metadata: deserializeMetadata(output),
|
|
2114
|
-
};
|
|
2115
|
-
break;
|
|
2116
|
-
default:
|
|
2117
|
-
const parsedBody = parsedOutput.body;
|
|
2118
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2119
|
-
response = {
|
|
2120
|
-
...parsedBody,
|
|
2121
|
-
name: `${errorCode}`,
|
|
2122
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2123
|
-
$fault: "client",
|
|
2124
|
-
$metadata: deserializeMetadata(output),
|
|
2125
|
-
} as any;
|
|
2126
|
-
}
|
|
2127
|
-
const message = response.message || response.Message || errorCode;
|
|
2128
|
-
response.message = message;
|
|
2129
|
-
delete response.Message;
|
|
2130
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2131
|
-
};
|
|
2132
|
-
|
|
2133
|
-
export const deserializeAws_restJson1DescribeFileSystemPolicyCommand = async (
|
|
2134
|
-
output: __HttpResponse,
|
|
2135
|
-
context: __SerdeContext
|
|
2136
|
-
): Promise<DescribeFileSystemPolicyCommandOutput> => {
|
|
2137
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2138
|
-
return deserializeAws_restJson1DescribeFileSystemPolicyCommandError(output, context);
|
|
2139
|
-
}
|
|
2140
|
-
const contents: DescribeFileSystemPolicyCommandOutput = {
|
|
2141
|
-
$metadata: deserializeMetadata(output),
|
|
2142
|
-
FileSystemId: undefined,
|
|
2143
|
-
Policy: undefined,
|
|
2144
|
-
};
|
|
2145
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2146
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
2147
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
2148
|
-
}
|
|
2149
|
-
if (data.Policy !== undefined && data.Policy !== null) {
|
|
2150
|
-
contents.Policy = __expectString(data.Policy);
|
|
2151
|
-
}
|
|
2152
|
-
return Promise.resolve(contents);
|
|
2153
|
-
};
|
|
2154
|
-
|
|
2155
|
-
const deserializeAws_restJson1DescribeFileSystemPolicyCommandError = async (
|
|
2156
|
-
output: __HttpResponse,
|
|
2157
|
-
context: __SerdeContext
|
|
2158
|
-
): Promise<DescribeFileSystemPolicyCommandOutput> => {
|
|
2159
|
-
const parsedOutput: any = {
|
|
2160
|
-
...output,
|
|
2161
|
-
body: await parseBody(output.body, context),
|
|
2162
|
-
};
|
|
2163
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2164
|
-
let errorCode: string = "UnknownError";
|
|
2165
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2166
|
-
switch (errorCode) {
|
|
2167
|
-
case "FileSystemNotFound":
|
|
2168
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2169
|
-
response = {
|
|
2170
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2171
|
-
name: errorCode,
|
|
2172
|
-
$metadata: deserializeMetadata(output),
|
|
2173
|
-
};
|
|
2174
|
-
break;
|
|
2175
|
-
case "InternalServerError":
|
|
2176
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2177
|
-
response = {
|
|
2178
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2179
|
-
name: errorCode,
|
|
2180
|
-
$metadata: deserializeMetadata(output),
|
|
2181
|
-
};
|
|
2182
|
-
break;
|
|
2183
|
-
case "PolicyNotFound":
|
|
2184
|
-
case "com.amazonaws.efs#PolicyNotFound":
|
|
2185
|
-
response = {
|
|
2186
|
-
...(await deserializeAws_restJson1PolicyNotFoundResponse(parsedOutput, context)),
|
|
2187
|
-
name: errorCode,
|
|
2188
|
-
$metadata: deserializeMetadata(output),
|
|
2189
|
-
};
|
|
2190
|
-
break;
|
|
2191
|
-
default:
|
|
2192
|
-
const parsedBody = parsedOutput.body;
|
|
2193
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2194
|
-
response = {
|
|
2195
|
-
...parsedBody,
|
|
2196
|
-
name: `${errorCode}`,
|
|
2197
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2198
|
-
$fault: "client",
|
|
2199
|
-
$metadata: deserializeMetadata(output),
|
|
2200
|
-
} as any;
|
|
2201
|
-
}
|
|
2202
|
-
const message = response.message || response.Message || errorCode;
|
|
2203
|
-
response.message = message;
|
|
2204
|
-
delete response.Message;
|
|
2205
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2206
|
-
};
|
|
2207
|
-
|
|
2208
|
-
export const deserializeAws_restJson1DescribeFileSystemsCommand = async (
|
|
2209
|
-
output: __HttpResponse,
|
|
2210
|
-
context: __SerdeContext
|
|
2211
|
-
): Promise<DescribeFileSystemsCommandOutput> => {
|
|
2212
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2213
|
-
return deserializeAws_restJson1DescribeFileSystemsCommandError(output, context);
|
|
2214
|
-
}
|
|
2215
|
-
const contents: DescribeFileSystemsCommandOutput = {
|
|
2216
|
-
$metadata: deserializeMetadata(output),
|
|
2217
|
-
FileSystems: undefined,
|
|
2218
|
-
Marker: undefined,
|
|
2219
|
-
NextMarker: undefined,
|
|
2220
|
-
};
|
|
2221
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2222
|
-
if (data.FileSystems !== undefined && data.FileSystems !== null) {
|
|
2223
|
-
contents.FileSystems = deserializeAws_restJson1FileSystemDescriptions(data.FileSystems, context);
|
|
2224
|
-
}
|
|
2225
|
-
if (data.Marker !== undefined && data.Marker !== null) {
|
|
2226
|
-
contents.Marker = __expectString(data.Marker);
|
|
2227
|
-
}
|
|
2228
|
-
if (data.NextMarker !== undefined && data.NextMarker !== null) {
|
|
2229
|
-
contents.NextMarker = __expectString(data.NextMarker);
|
|
2230
|
-
}
|
|
2231
|
-
return Promise.resolve(contents);
|
|
2232
|
-
};
|
|
2233
|
-
|
|
2234
|
-
const deserializeAws_restJson1DescribeFileSystemsCommandError = async (
|
|
2235
|
-
output: __HttpResponse,
|
|
2236
|
-
context: __SerdeContext
|
|
2237
|
-
): Promise<DescribeFileSystemsCommandOutput> => {
|
|
2238
|
-
const parsedOutput: any = {
|
|
2239
|
-
...output,
|
|
2240
|
-
body: await parseBody(output.body, context),
|
|
2241
|
-
};
|
|
2242
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2243
|
-
let errorCode: string = "UnknownError";
|
|
2244
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2245
|
-
switch (errorCode) {
|
|
2246
|
-
case "BadRequest":
|
|
2247
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2248
|
-
response = {
|
|
2249
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2250
|
-
name: errorCode,
|
|
2251
|
-
$metadata: deserializeMetadata(output),
|
|
2252
|
-
};
|
|
2253
|
-
break;
|
|
2254
|
-
case "FileSystemNotFound":
|
|
2255
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2256
|
-
response = {
|
|
2257
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2258
|
-
name: errorCode,
|
|
2259
|
-
$metadata: deserializeMetadata(output),
|
|
2260
|
-
};
|
|
2261
|
-
break;
|
|
2262
|
-
case "InternalServerError":
|
|
2263
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2264
|
-
response = {
|
|
2265
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2266
|
-
name: errorCode,
|
|
2267
|
-
$metadata: deserializeMetadata(output),
|
|
2268
|
-
};
|
|
2269
|
-
break;
|
|
2270
|
-
default:
|
|
2271
|
-
const parsedBody = parsedOutput.body;
|
|
2272
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2273
|
-
response = {
|
|
2274
|
-
...parsedBody,
|
|
2275
|
-
name: `${errorCode}`,
|
|
2276
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2277
|
-
$fault: "client",
|
|
2278
|
-
$metadata: deserializeMetadata(output),
|
|
2279
|
-
} as any;
|
|
2280
|
-
}
|
|
2281
|
-
const message = response.message || response.Message || errorCode;
|
|
2282
|
-
response.message = message;
|
|
2283
|
-
delete response.Message;
|
|
2284
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2285
|
-
};
|
|
2286
|
-
|
|
2287
|
-
export const deserializeAws_restJson1DescribeLifecycleConfigurationCommand = async (
|
|
2288
|
-
output: __HttpResponse,
|
|
2289
|
-
context: __SerdeContext
|
|
2290
|
-
): Promise<DescribeLifecycleConfigurationCommandOutput> => {
|
|
2291
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2292
|
-
return deserializeAws_restJson1DescribeLifecycleConfigurationCommandError(output, context);
|
|
2293
|
-
}
|
|
2294
|
-
const contents: DescribeLifecycleConfigurationCommandOutput = {
|
|
2295
|
-
$metadata: deserializeMetadata(output),
|
|
2296
|
-
LifecyclePolicies: undefined,
|
|
2297
|
-
};
|
|
2298
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2299
|
-
if (data.LifecyclePolicies !== undefined && data.LifecyclePolicies !== null) {
|
|
2300
|
-
contents.LifecyclePolicies = deserializeAws_restJson1LifecyclePolicies(data.LifecyclePolicies, context);
|
|
2301
|
-
}
|
|
2302
|
-
return Promise.resolve(contents);
|
|
2303
|
-
};
|
|
2304
|
-
|
|
2305
|
-
const deserializeAws_restJson1DescribeLifecycleConfigurationCommandError = async (
|
|
2306
|
-
output: __HttpResponse,
|
|
2307
|
-
context: __SerdeContext
|
|
2308
|
-
): Promise<DescribeLifecycleConfigurationCommandOutput> => {
|
|
2309
|
-
const parsedOutput: any = {
|
|
2310
|
-
...output,
|
|
2311
|
-
body: await parseBody(output.body, context),
|
|
2312
|
-
};
|
|
2313
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2314
|
-
let errorCode: string = "UnknownError";
|
|
2315
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2316
|
-
switch (errorCode) {
|
|
2317
|
-
case "BadRequest":
|
|
2318
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2319
|
-
response = {
|
|
2320
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2321
|
-
name: errorCode,
|
|
2322
|
-
$metadata: deserializeMetadata(output),
|
|
2323
|
-
};
|
|
2324
|
-
break;
|
|
2325
|
-
case "FileSystemNotFound":
|
|
2326
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2327
|
-
response = {
|
|
2328
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2329
|
-
name: errorCode,
|
|
2330
|
-
$metadata: deserializeMetadata(output),
|
|
2331
|
-
};
|
|
2332
|
-
break;
|
|
2333
|
-
case "InternalServerError":
|
|
2334
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2335
|
-
response = {
|
|
2336
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2337
|
-
name: errorCode,
|
|
2338
|
-
$metadata: deserializeMetadata(output),
|
|
2339
|
-
};
|
|
2340
|
-
break;
|
|
2341
|
-
default:
|
|
2342
|
-
const parsedBody = parsedOutput.body;
|
|
2343
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2344
|
-
response = {
|
|
2345
|
-
...parsedBody,
|
|
2346
|
-
name: `${errorCode}`,
|
|
2347
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2348
|
-
$fault: "client",
|
|
2349
|
-
$metadata: deserializeMetadata(output),
|
|
2350
|
-
} as any;
|
|
2351
|
-
}
|
|
2352
|
-
const message = response.message || response.Message || errorCode;
|
|
2353
|
-
response.message = message;
|
|
2354
|
-
delete response.Message;
|
|
2355
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2356
|
-
};
|
|
2357
|
-
|
|
2358
|
-
export const deserializeAws_restJson1DescribeMountTargetsCommand = async (
|
|
2359
|
-
output: __HttpResponse,
|
|
2360
|
-
context: __SerdeContext
|
|
2361
|
-
): Promise<DescribeMountTargetsCommandOutput> => {
|
|
2362
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2363
|
-
return deserializeAws_restJson1DescribeMountTargetsCommandError(output, context);
|
|
2364
|
-
}
|
|
2365
|
-
const contents: DescribeMountTargetsCommandOutput = {
|
|
2366
|
-
$metadata: deserializeMetadata(output),
|
|
2367
|
-
Marker: undefined,
|
|
2368
|
-
MountTargets: undefined,
|
|
2369
|
-
NextMarker: undefined,
|
|
2370
|
-
};
|
|
2371
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2372
|
-
if (data.Marker !== undefined && data.Marker !== null) {
|
|
2373
|
-
contents.Marker = __expectString(data.Marker);
|
|
2374
|
-
}
|
|
2375
|
-
if (data.MountTargets !== undefined && data.MountTargets !== null) {
|
|
2376
|
-
contents.MountTargets = deserializeAws_restJson1MountTargetDescriptions(data.MountTargets, context);
|
|
2377
|
-
}
|
|
2378
|
-
if (data.NextMarker !== undefined && data.NextMarker !== null) {
|
|
2379
|
-
contents.NextMarker = __expectString(data.NextMarker);
|
|
2380
|
-
}
|
|
2381
|
-
return Promise.resolve(contents);
|
|
2382
|
-
};
|
|
2383
|
-
|
|
2384
|
-
const deserializeAws_restJson1DescribeMountTargetsCommandError = async (
|
|
2385
|
-
output: __HttpResponse,
|
|
2386
|
-
context: __SerdeContext
|
|
2387
|
-
): Promise<DescribeMountTargetsCommandOutput> => {
|
|
2388
|
-
const parsedOutput: any = {
|
|
2389
|
-
...output,
|
|
2390
|
-
body: await parseBody(output.body, context),
|
|
2391
|
-
};
|
|
2392
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2393
|
-
let errorCode: string = "UnknownError";
|
|
2394
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2395
|
-
switch (errorCode) {
|
|
2396
|
-
case "AccessPointNotFound":
|
|
2397
|
-
case "com.amazonaws.efs#AccessPointNotFound":
|
|
2398
|
-
response = {
|
|
2399
|
-
...(await deserializeAws_restJson1AccessPointNotFoundResponse(parsedOutput, context)),
|
|
2400
|
-
name: errorCode,
|
|
2401
|
-
$metadata: deserializeMetadata(output),
|
|
2402
|
-
};
|
|
2403
|
-
break;
|
|
2404
|
-
case "BadRequest":
|
|
2405
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2406
|
-
response = {
|
|
2407
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2408
|
-
name: errorCode,
|
|
2409
|
-
$metadata: deserializeMetadata(output),
|
|
2410
|
-
};
|
|
2411
|
-
break;
|
|
2412
|
-
case "FileSystemNotFound":
|
|
2413
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2414
|
-
response = {
|
|
2415
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2416
|
-
name: errorCode,
|
|
2417
|
-
$metadata: deserializeMetadata(output),
|
|
2418
|
-
};
|
|
2419
|
-
break;
|
|
2420
|
-
case "InternalServerError":
|
|
2421
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2422
|
-
response = {
|
|
2423
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2424
|
-
name: errorCode,
|
|
2425
|
-
$metadata: deserializeMetadata(output),
|
|
2426
|
-
};
|
|
2427
|
-
break;
|
|
2428
|
-
case "MountTargetNotFound":
|
|
2429
|
-
case "com.amazonaws.efs#MountTargetNotFound":
|
|
2430
|
-
response = {
|
|
2431
|
-
...(await deserializeAws_restJson1MountTargetNotFoundResponse(parsedOutput, context)),
|
|
2432
|
-
name: errorCode,
|
|
2433
|
-
$metadata: deserializeMetadata(output),
|
|
2434
|
-
};
|
|
2435
|
-
break;
|
|
2436
|
-
default:
|
|
2437
|
-
const parsedBody = parsedOutput.body;
|
|
2438
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2439
|
-
response = {
|
|
2440
|
-
...parsedBody,
|
|
2441
|
-
name: `${errorCode}`,
|
|
2442
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2443
|
-
$fault: "client",
|
|
2444
|
-
$metadata: deserializeMetadata(output),
|
|
2445
|
-
} as any;
|
|
2446
|
-
}
|
|
2447
|
-
const message = response.message || response.Message || errorCode;
|
|
2448
|
-
response.message = message;
|
|
2449
|
-
delete response.Message;
|
|
2450
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2451
|
-
};
|
|
2452
|
-
|
|
2453
|
-
export const deserializeAws_restJson1DescribeMountTargetSecurityGroupsCommand = async (
|
|
2454
|
-
output: __HttpResponse,
|
|
2455
|
-
context: __SerdeContext
|
|
2456
|
-
): Promise<DescribeMountTargetSecurityGroupsCommandOutput> => {
|
|
2457
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2458
|
-
return deserializeAws_restJson1DescribeMountTargetSecurityGroupsCommandError(output, context);
|
|
2459
|
-
}
|
|
2460
|
-
const contents: DescribeMountTargetSecurityGroupsCommandOutput = {
|
|
2461
|
-
$metadata: deserializeMetadata(output),
|
|
2462
|
-
SecurityGroups: undefined,
|
|
2463
|
-
};
|
|
2464
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2465
|
-
if (data.SecurityGroups !== undefined && data.SecurityGroups !== null) {
|
|
2466
|
-
contents.SecurityGroups = deserializeAws_restJson1SecurityGroups(data.SecurityGroups, context);
|
|
2467
|
-
}
|
|
2468
|
-
return Promise.resolve(contents);
|
|
2469
|
-
};
|
|
2470
|
-
|
|
2471
|
-
const deserializeAws_restJson1DescribeMountTargetSecurityGroupsCommandError = async (
|
|
2472
|
-
output: __HttpResponse,
|
|
2473
|
-
context: __SerdeContext
|
|
2474
|
-
): Promise<DescribeMountTargetSecurityGroupsCommandOutput> => {
|
|
2475
|
-
const parsedOutput: any = {
|
|
2476
|
-
...output,
|
|
2477
|
-
body: await parseBody(output.body, context),
|
|
2478
|
-
};
|
|
2479
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2480
|
-
let errorCode: string = "UnknownError";
|
|
2481
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2482
|
-
switch (errorCode) {
|
|
2483
|
-
case "BadRequest":
|
|
2484
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2485
|
-
response = {
|
|
2486
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2487
|
-
name: errorCode,
|
|
2488
|
-
$metadata: deserializeMetadata(output),
|
|
2489
|
-
};
|
|
2490
|
-
break;
|
|
2491
|
-
case "IncorrectMountTargetState":
|
|
2492
|
-
case "com.amazonaws.efs#IncorrectMountTargetState":
|
|
2493
|
-
response = {
|
|
2494
|
-
...(await deserializeAws_restJson1IncorrectMountTargetStateResponse(parsedOutput, context)),
|
|
2495
|
-
name: errorCode,
|
|
2496
|
-
$metadata: deserializeMetadata(output),
|
|
2497
|
-
};
|
|
2498
|
-
break;
|
|
2499
|
-
case "InternalServerError":
|
|
2500
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2501
|
-
response = {
|
|
2502
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2503
|
-
name: errorCode,
|
|
2504
|
-
$metadata: deserializeMetadata(output),
|
|
2505
|
-
};
|
|
2506
|
-
break;
|
|
2507
|
-
case "MountTargetNotFound":
|
|
2508
|
-
case "com.amazonaws.efs#MountTargetNotFound":
|
|
2509
|
-
response = {
|
|
2510
|
-
...(await deserializeAws_restJson1MountTargetNotFoundResponse(parsedOutput, context)),
|
|
2511
|
-
name: errorCode,
|
|
2512
|
-
$metadata: deserializeMetadata(output),
|
|
2513
|
-
};
|
|
2514
|
-
break;
|
|
2515
|
-
default:
|
|
2516
|
-
const parsedBody = parsedOutput.body;
|
|
2517
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2518
|
-
response = {
|
|
2519
|
-
...parsedBody,
|
|
2520
|
-
name: `${errorCode}`,
|
|
2521
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2522
|
-
$fault: "client",
|
|
2523
|
-
$metadata: deserializeMetadata(output),
|
|
2524
|
-
} as any;
|
|
2525
|
-
}
|
|
2526
|
-
const message = response.message || response.Message || errorCode;
|
|
2527
|
-
response.message = message;
|
|
2528
|
-
delete response.Message;
|
|
2529
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2530
|
-
};
|
|
2531
|
-
|
|
2532
|
-
export const deserializeAws_restJson1DescribeTagsCommand = async (
|
|
2533
|
-
output: __HttpResponse,
|
|
2534
|
-
context: __SerdeContext
|
|
2535
|
-
): Promise<DescribeTagsCommandOutput> => {
|
|
2536
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2537
|
-
return deserializeAws_restJson1DescribeTagsCommandError(output, context);
|
|
2538
|
-
}
|
|
2539
|
-
const contents: DescribeTagsCommandOutput = {
|
|
2540
|
-
$metadata: deserializeMetadata(output),
|
|
2541
|
-
Marker: undefined,
|
|
2542
|
-
NextMarker: undefined,
|
|
2543
|
-
Tags: undefined,
|
|
2544
|
-
};
|
|
2545
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2546
|
-
if (data.Marker !== undefined && data.Marker !== null) {
|
|
2547
|
-
contents.Marker = __expectString(data.Marker);
|
|
2548
|
-
}
|
|
2549
|
-
if (data.NextMarker !== undefined && data.NextMarker !== null) {
|
|
2550
|
-
contents.NextMarker = __expectString(data.NextMarker);
|
|
2551
|
-
}
|
|
2552
|
-
if (data.Tags !== undefined && data.Tags !== null) {
|
|
2553
|
-
contents.Tags = deserializeAws_restJson1Tags(data.Tags, context);
|
|
2554
|
-
}
|
|
2555
|
-
return Promise.resolve(contents);
|
|
2556
|
-
};
|
|
2557
|
-
|
|
2558
|
-
const deserializeAws_restJson1DescribeTagsCommandError = async (
|
|
2559
|
-
output: __HttpResponse,
|
|
2560
|
-
context: __SerdeContext
|
|
2561
|
-
): Promise<DescribeTagsCommandOutput> => {
|
|
2562
|
-
const parsedOutput: any = {
|
|
2563
|
-
...output,
|
|
2564
|
-
body: await parseBody(output.body, context),
|
|
2565
|
-
};
|
|
2566
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2567
|
-
let errorCode: string = "UnknownError";
|
|
2568
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2569
|
-
switch (errorCode) {
|
|
2570
|
-
case "BadRequest":
|
|
2571
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2572
|
-
response = {
|
|
2573
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2574
|
-
name: errorCode,
|
|
2575
|
-
$metadata: deserializeMetadata(output),
|
|
2576
|
-
};
|
|
2577
|
-
break;
|
|
2578
|
-
case "FileSystemNotFound":
|
|
2579
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2580
|
-
response = {
|
|
2581
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2582
|
-
name: errorCode,
|
|
2583
|
-
$metadata: deserializeMetadata(output),
|
|
2584
|
-
};
|
|
2585
|
-
break;
|
|
2586
|
-
case "InternalServerError":
|
|
2587
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2588
|
-
response = {
|
|
2589
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2590
|
-
name: errorCode,
|
|
2591
|
-
$metadata: deserializeMetadata(output),
|
|
2592
|
-
};
|
|
2593
|
-
break;
|
|
2594
|
-
default:
|
|
2595
|
-
const parsedBody = parsedOutput.body;
|
|
2596
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2597
|
-
response = {
|
|
2598
|
-
...parsedBody,
|
|
2599
|
-
name: `${errorCode}`,
|
|
2600
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2601
|
-
$fault: "client",
|
|
2602
|
-
$metadata: deserializeMetadata(output),
|
|
2603
|
-
} as any;
|
|
2604
|
-
}
|
|
2605
|
-
const message = response.message || response.Message || errorCode;
|
|
2606
|
-
response.message = message;
|
|
2607
|
-
delete response.Message;
|
|
2608
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2609
|
-
};
|
|
2610
|
-
|
|
2611
|
-
export const deserializeAws_restJson1ListTagsForResourceCommand = async (
|
|
2612
|
-
output: __HttpResponse,
|
|
2613
|
-
context: __SerdeContext
|
|
2614
|
-
): Promise<ListTagsForResourceCommandOutput> => {
|
|
2615
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2616
|
-
return deserializeAws_restJson1ListTagsForResourceCommandError(output, context);
|
|
2617
|
-
}
|
|
2618
|
-
const contents: ListTagsForResourceCommandOutput = {
|
|
2619
|
-
$metadata: deserializeMetadata(output),
|
|
2620
|
-
NextToken: undefined,
|
|
2621
|
-
Tags: undefined,
|
|
2622
|
-
};
|
|
2623
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2624
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
2625
|
-
contents.NextToken = __expectString(data.NextToken);
|
|
2626
|
-
}
|
|
2627
|
-
if (data.Tags !== undefined && data.Tags !== null) {
|
|
2628
|
-
contents.Tags = deserializeAws_restJson1Tags(data.Tags, context);
|
|
2629
|
-
}
|
|
2630
|
-
return Promise.resolve(contents);
|
|
2631
|
-
};
|
|
2632
|
-
|
|
2633
|
-
const deserializeAws_restJson1ListTagsForResourceCommandError = async (
|
|
2634
|
-
output: __HttpResponse,
|
|
2635
|
-
context: __SerdeContext
|
|
2636
|
-
): Promise<ListTagsForResourceCommandOutput> => {
|
|
2637
|
-
const parsedOutput: any = {
|
|
2638
|
-
...output,
|
|
2639
|
-
body: await parseBody(output.body, context),
|
|
2640
|
-
};
|
|
2641
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2642
|
-
let errorCode: string = "UnknownError";
|
|
2643
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2644
|
-
switch (errorCode) {
|
|
2645
|
-
case "AccessPointNotFound":
|
|
2646
|
-
case "com.amazonaws.efs#AccessPointNotFound":
|
|
2647
|
-
response = {
|
|
2648
|
-
...(await deserializeAws_restJson1AccessPointNotFoundResponse(parsedOutput, context)),
|
|
2649
|
-
name: errorCode,
|
|
2650
|
-
$metadata: deserializeMetadata(output),
|
|
2651
|
-
};
|
|
2652
|
-
break;
|
|
2653
|
-
case "BadRequest":
|
|
2654
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2655
|
-
response = {
|
|
2656
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2657
|
-
name: errorCode,
|
|
2658
|
-
$metadata: deserializeMetadata(output),
|
|
2659
|
-
};
|
|
2660
|
-
break;
|
|
2661
|
-
case "FileSystemNotFound":
|
|
2662
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2663
|
-
response = {
|
|
2664
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2665
|
-
name: errorCode,
|
|
2666
|
-
$metadata: deserializeMetadata(output),
|
|
2667
|
-
};
|
|
2668
|
-
break;
|
|
2669
|
-
case "InternalServerError":
|
|
2670
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2671
|
-
response = {
|
|
2672
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2673
|
-
name: errorCode,
|
|
2674
|
-
$metadata: deserializeMetadata(output),
|
|
2675
|
-
};
|
|
2676
|
-
break;
|
|
2677
|
-
default:
|
|
2678
|
-
const parsedBody = parsedOutput.body;
|
|
2679
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2680
|
-
response = {
|
|
2681
|
-
...parsedBody,
|
|
2682
|
-
name: `${errorCode}`,
|
|
2683
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2684
|
-
$fault: "client",
|
|
2685
|
-
$metadata: deserializeMetadata(output),
|
|
2686
|
-
} as any;
|
|
2687
|
-
}
|
|
2688
|
-
const message = response.message || response.Message || errorCode;
|
|
2689
|
-
response.message = message;
|
|
2690
|
-
delete response.Message;
|
|
2691
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2692
|
-
};
|
|
2693
|
-
|
|
2694
|
-
export const deserializeAws_restJson1ModifyMountTargetSecurityGroupsCommand = async (
|
|
2695
|
-
output: __HttpResponse,
|
|
2696
|
-
context: __SerdeContext
|
|
2697
|
-
): Promise<ModifyMountTargetSecurityGroupsCommandOutput> => {
|
|
2698
|
-
if (output.statusCode !== 204 && output.statusCode >= 300) {
|
|
2699
|
-
return deserializeAws_restJson1ModifyMountTargetSecurityGroupsCommandError(output, context);
|
|
2700
|
-
}
|
|
2701
|
-
const contents: ModifyMountTargetSecurityGroupsCommandOutput = {
|
|
2702
|
-
$metadata: deserializeMetadata(output),
|
|
2703
|
-
};
|
|
2704
|
-
await collectBody(output.body, context);
|
|
2705
|
-
return Promise.resolve(contents);
|
|
2706
|
-
};
|
|
2707
|
-
|
|
2708
|
-
const deserializeAws_restJson1ModifyMountTargetSecurityGroupsCommandError = async (
|
|
2709
|
-
output: __HttpResponse,
|
|
2710
|
-
context: __SerdeContext
|
|
2711
|
-
): Promise<ModifyMountTargetSecurityGroupsCommandOutput> => {
|
|
2712
|
-
const parsedOutput: any = {
|
|
2713
|
-
...output,
|
|
2714
|
-
body: await parseBody(output.body, context),
|
|
2715
|
-
};
|
|
2716
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2717
|
-
let errorCode: string = "UnknownError";
|
|
2718
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2719
|
-
switch (errorCode) {
|
|
2720
|
-
case "BadRequest":
|
|
2721
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2722
|
-
response = {
|
|
2723
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2724
|
-
name: errorCode,
|
|
2725
|
-
$metadata: deserializeMetadata(output),
|
|
2726
|
-
};
|
|
2727
|
-
break;
|
|
2728
|
-
case "IncorrectMountTargetState":
|
|
2729
|
-
case "com.amazonaws.efs#IncorrectMountTargetState":
|
|
2730
|
-
response = {
|
|
2731
|
-
...(await deserializeAws_restJson1IncorrectMountTargetStateResponse(parsedOutput, context)),
|
|
2732
|
-
name: errorCode,
|
|
2733
|
-
$metadata: deserializeMetadata(output),
|
|
2734
|
-
};
|
|
2735
|
-
break;
|
|
2736
|
-
case "InternalServerError":
|
|
2737
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2738
|
-
response = {
|
|
2739
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2740
|
-
name: errorCode,
|
|
2741
|
-
$metadata: deserializeMetadata(output),
|
|
2742
|
-
};
|
|
2743
|
-
break;
|
|
2744
|
-
case "MountTargetNotFound":
|
|
2745
|
-
case "com.amazonaws.efs#MountTargetNotFound":
|
|
2746
|
-
response = {
|
|
2747
|
-
...(await deserializeAws_restJson1MountTargetNotFoundResponse(parsedOutput, context)),
|
|
2748
|
-
name: errorCode,
|
|
2749
|
-
$metadata: deserializeMetadata(output),
|
|
2750
|
-
};
|
|
2751
|
-
break;
|
|
2752
|
-
case "SecurityGroupLimitExceeded":
|
|
2753
|
-
case "com.amazonaws.efs#SecurityGroupLimitExceeded":
|
|
2754
|
-
response = {
|
|
2755
|
-
...(await deserializeAws_restJson1SecurityGroupLimitExceededResponse(parsedOutput, context)),
|
|
2756
|
-
name: errorCode,
|
|
2757
|
-
$metadata: deserializeMetadata(output),
|
|
2758
|
-
};
|
|
2759
|
-
break;
|
|
2760
|
-
case "SecurityGroupNotFound":
|
|
2761
|
-
case "com.amazonaws.efs#SecurityGroupNotFound":
|
|
2762
|
-
response = {
|
|
2763
|
-
...(await deserializeAws_restJson1SecurityGroupNotFoundResponse(parsedOutput, context)),
|
|
2764
|
-
name: errorCode,
|
|
2765
|
-
$metadata: deserializeMetadata(output),
|
|
2766
|
-
};
|
|
2767
|
-
break;
|
|
2768
|
-
default:
|
|
2769
|
-
const parsedBody = parsedOutput.body;
|
|
2770
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2771
|
-
response = {
|
|
2772
|
-
...parsedBody,
|
|
2773
|
-
name: `${errorCode}`,
|
|
2774
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2775
|
-
$fault: "client",
|
|
2776
|
-
$metadata: deserializeMetadata(output),
|
|
2777
|
-
} as any;
|
|
2778
|
-
}
|
|
2779
|
-
const message = response.message || response.Message || errorCode;
|
|
2780
|
-
response.message = message;
|
|
2781
|
-
delete response.Message;
|
|
2782
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2783
|
-
};
|
|
2784
|
-
|
|
2785
|
-
export const deserializeAws_restJson1PutAccountPreferencesCommand = async (
|
|
2786
|
-
output: __HttpResponse,
|
|
2787
|
-
context: __SerdeContext
|
|
2788
|
-
): Promise<PutAccountPreferencesCommandOutput> => {
|
|
2789
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2790
|
-
return deserializeAws_restJson1PutAccountPreferencesCommandError(output, context);
|
|
2791
|
-
}
|
|
2792
|
-
const contents: PutAccountPreferencesCommandOutput = {
|
|
2793
|
-
$metadata: deserializeMetadata(output),
|
|
2794
|
-
ResourceIdPreference: undefined,
|
|
2795
|
-
};
|
|
2796
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2797
|
-
if (data.ResourceIdPreference !== undefined && data.ResourceIdPreference !== null) {
|
|
2798
|
-
contents.ResourceIdPreference = deserializeAws_restJson1ResourceIdPreference(data.ResourceIdPreference, context);
|
|
2799
|
-
}
|
|
2800
|
-
return Promise.resolve(contents);
|
|
2801
|
-
};
|
|
2802
|
-
|
|
2803
|
-
const deserializeAws_restJson1PutAccountPreferencesCommandError = async (
|
|
2804
|
-
output: __HttpResponse,
|
|
2805
|
-
context: __SerdeContext
|
|
2806
|
-
): Promise<PutAccountPreferencesCommandOutput> => {
|
|
2807
|
-
const parsedOutput: any = {
|
|
2808
|
-
...output,
|
|
2809
|
-
body: await parseBody(output.body, context),
|
|
2810
|
-
};
|
|
2811
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2812
|
-
let errorCode: string = "UnknownError";
|
|
2813
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2814
|
-
switch (errorCode) {
|
|
2815
|
-
case "InternalServerError":
|
|
2816
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2817
|
-
response = {
|
|
2818
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2819
|
-
name: errorCode,
|
|
2820
|
-
$metadata: deserializeMetadata(output),
|
|
2821
|
-
};
|
|
2822
|
-
break;
|
|
2823
|
-
default:
|
|
2824
|
-
const parsedBody = parsedOutput.body;
|
|
2825
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2826
|
-
response = {
|
|
2827
|
-
...parsedBody,
|
|
2828
|
-
name: `${errorCode}`,
|
|
2829
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2830
|
-
$fault: "client",
|
|
2831
|
-
$metadata: deserializeMetadata(output),
|
|
2832
|
-
} as any;
|
|
2833
|
-
}
|
|
2834
|
-
const message = response.message || response.Message || errorCode;
|
|
2835
|
-
response.message = message;
|
|
2836
|
-
delete response.Message;
|
|
2837
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2838
|
-
};
|
|
2839
|
-
|
|
2840
|
-
export const deserializeAws_restJson1PutBackupPolicyCommand = async (
|
|
2841
|
-
output: __HttpResponse,
|
|
2842
|
-
context: __SerdeContext
|
|
2843
|
-
): Promise<PutBackupPolicyCommandOutput> => {
|
|
2844
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2845
|
-
return deserializeAws_restJson1PutBackupPolicyCommandError(output, context);
|
|
2846
|
-
}
|
|
2847
|
-
const contents: PutBackupPolicyCommandOutput = {
|
|
2848
|
-
$metadata: deserializeMetadata(output),
|
|
2849
|
-
BackupPolicy: undefined,
|
|
2850
|
-
};
|
|
2851
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2852
|
-
if (data.BackupPolicy !== undefined && data.BackupPolicy !== null) {
|
|
2853
|
-
contents.BackupPolicy = deserializeAws_restJson1BackupPolicy(data.BackupPolicy, context);
|
|
2854
|
-
}
|
|
2855
|
-
return Promise.resolve(contents);
|
|
2856
|
-
};
|
|
2857
|
-
|
|
2858
|
-
const deserializeAws_restJson1PutBackupPolicyCommandError = async (
|
|
2859
|
-
output: __HttpResponse,
|
|
2860
|
-
context: __SerdeContext
|
|
2861
|
-
): Promise<PutBackupPolicyCommandOutput> => {
|
|
2862
|
-
const parsedOutput: any = {
|
|
2863
|
-
...output,
|
|
2864
|
-
body: await parseBody(output.body, context),
|
|
2865
|
-
};
|
|
2866
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2867
|
-
let errorCode: string = "UnknownError";
|
|
2868
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2869
|
-
switch (errorCode) {
|
|
2870
|
-
case "BadRequest":
|
|
2871
|
-
case "com.amazonaws.efs#BadRequest":
|
|
2872
|
-
response = {
|
|
2873
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
2874
|
-
name: errorCode,
|
|
2875
|
-
$metadata: deserializeMetadata(output),
|
|
2876
|
-
};
|
|
2877
|
-
break;
|
|
2878
|
-
case "FileSystemNotFound":
|
|
2879
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2880
|
-
response = {
|
|
2881
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2882
|
-
name: errorCode,
|
|
2883
|
-
$metadata: deserializeMetadata(output),
|
|
2884
|
-
};
|
|
2885
|
-
break;
|
|
2886
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
2887
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
2888
|
-
response = {
|
|
2889
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
2890
|
-
name: errorCode,
|
|
2891
|
-
$metadata: deserializeMetadata(output),
|
|
2892
|
-
};
|
|
2893
|
-
break;
|
|
2894
|
-
case "InternalServerError":
|
|
2895
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2896
|
-
response = {
|
|
2897
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2898
|
-
name: errorCode,
|
|
2899
|
-
$metadata: deserializeMetadata(output),
|
|
2900
|
-
};
|
|
2901
|
-
break;
|
|
2902
|
-
case "ValidationException":
|
|
2903
|
-
case "com.amazonaws.efs#ValidationException":
|
|
2904
|
-
response = {
|
|
2905
|
-
...(await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)),
|
|
2906
|
-
name: errorCode,
|
|
2907
|
-
$metadata: deserializeMetadata(output),
|
|
2908
|
-
};
|
|
2909
|
-
break;
|
|
2910
|
-
default:
|
|
2911
|
-
const parsedBody = parsedOutput.body;
|
|
2912
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2913
|
-
response = {
|
|
2914
|
-
...parsedBody,
|
|
2915
|
-
name: `${errorCode}`,
|
|
2916
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
2917
|
-
$fault: "client",
|
|
2918
|
-
$metadata: deserializeMetadata(output),
|
|
2919
|
-
} as any;
|
|
2920
|
-
}
|
|
2921
|
-
const message = response.message || response.Message || errorCode;
|
|
2922
|
-
response.message = message;
|
|
2923
|
-
delete response.Message;
|
|
2924
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
2925
|
-
};
|
|
2926
|
-
|
|
2927
|
-
export const deserializeAws_restJson1PutFileSystemPolicyCommand = async (
|
|
2928
|
-
output: __HttpResponse,
|
|
2929
|
-
context: __SerdeContext
|
|
2930
|
-
): Promise<PutFileSystemPolicyCommandOutput> => {
|
|
2931
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
2932
|
-
return deserializeAws_restJson1PutFileSystemPolicyCommandError(output, context);
|
|
2933
|
-
}
|
|
2934
|
-
const contents: PutFileSystemPolicyCommandOutput = {
|
|
2935
|
-
$metadata: deserializeMetadata(output),
|
|
2936
|
-
FileSystemId: undefined,
|
|
2937
|
-
Policy: undefined,
|
|
2938
|
-
};
|
|
2939
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
2940
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
2941
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
2942
|
-
}
|
|
2943
|
-
if (data.Policy !== undefined && data.Policy !== null) {
|
|
2944
|
-
contents.Policy = __expectString(data.Policy);
|
|
2945
|
-
}
|
|
2946
|
-
return Promise.resolve(contents);
|
|
2947
|
-
};
|
|
2948
|
-
|
|
2949
|
-
const deserializeAws_restJson1PutFileSystemPolicyCommandError = async (
|
|
2950
|
-
output: __HttpResponse,
|
|
2951
|
-
context: __SerdeContext
|
|
2952
|
-
): Promise<PutFileSystemPolicyCommandOutput> => {
|
|
2953
|
-
const parsedOutput: any = {
|
|
2954
|
-
...output,
|
|
2955
|
-
body: await parseBody(output.body, context),
|
|
2956
|
-
};
|
|
2957
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
2958
|
-
let errorCode: string = "UnknownError";
|
|
2959
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
2960
|
-
switch (errorCode) {
|
|
2961
|
-
case "FileSystemNotFound":
|
|
2962
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
2963
|
-
response = {
|
|
2964
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
2965
|
-
name: errorCode,
|
|
2966
|
-
$metadata: deserializeMetadata(output),
|
|
2967
|
-
};
|
|
2968
|
-
break;
|
|
2969
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
2970
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
2971
|
-
response = {
|
|
2972
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
2973
|
-
name: errorCode,
|
|
2974
|
-
$metadata: deserializeMetadata(output),
|
|
2975
|
-
};
|
|
2976
|
-
break;
|
|
2977
|
-
case "InternalServerError":
|
|
2978
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
2979
|
-
response = {
|
|
2980
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
2981
|
-
name: errorCode,
|
|
2982
|
-
$metadata: deserializeMetadata(output),
|
|
2983
|
-
};
|
|
2984
|
-
break;
|
|
2985
|
-
case "InvalidPolicyException":
|
|
2986
|
-
case "com.amazonaws.efs#InvalidPolicyException":
|
|
2987
|
-
response = {
|
|
2988
|
-
...(await deserializeAws_restJson1InvalidPolicyExceptionResponse(parsedOutput, context)),
|
|
2989
|
-
name: errorCode,
|
|
2990
|
-
$metadata: deserializeMetadata(output),
|
|
2991
|
-
};
|
|
2992
|
-
break;
|
|
2993
|
-
default:
|
|
2994
|
-
const parsedBody = parsedOutput.body;
|
|
2995
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
2996
|
-
response = {
|
|
2997
|
-
...parsedBody,
|
|
2998
|
-
name: `${errorCode}`,
|
|
2999
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
3000
|
-
$fault: "client",
|
|
3001
|
-
$metadata: deserializeMetadata(output),
|
|
3002
|
-
} as any;
|
|
3003
|
-
}
|
|
3004
|
-
const message = response.message || response.Message || errorCode;
|
|
3005
|
-
response.message = message;
|
|
3006
|
-
delete response.Message;
|
|
3007
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
3008
|
-
};
|
|
3009
|
-
|
|
3010
|
-
export const deserializeAws_restJson1PutLifecycleConfigurationCommand = async (
|
|
3011
|
-
output: __HttpResponse,
|
|
3012
|
-
context: __SerdeContext
|
|
3013
|
-
): Promise<PutLifecycleConfigurationCommandOutput> => {
|
|
3014
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3015
|
-
return deserializeAws_restJson1PutLifecycleConfigurationCommandError(output, context);
|
|
3016
|
-
}
|
|
3017
|
-
const contents: PutLifecycleConfigurationCommandOutput = {
|
|
3018
|
-
$metadata: deserializeMetadata(output),
|
|
3019
|
-
LifecyclePolicies: undefined,
|
|
3020
|
-
};
|
|
3021
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
3022
|
-
if (data.LifecyclePolicies !== undefined && data.LifecyclePolicies !== null) {
|
|
3023
|
-
contents.LifecyclePolicies = deserializeAws_restJson1LifecyclePolicies(data.LifecyclePolicies, context);
|
|
3024
|
-
}
|
|
3025
|
-
return Promise.resolve(contents);
|
|
3026
|
-
};
|
|
3027
|
-
|
|
3028
|
-
const deserializeAws_restJson1PutLifecycleConfigurationCommandError = async (
|
|
3029
|
-
output: __HttpResponse,
|
|
3030
|
-
context: __SerdeContext
|
|
3031
|
-
): Promise<PutLifecycleConfigurationCommandOutput> => {
|
|
3032
|
-
const parsedOutput: any = {
|
|
3033
|
-
...output,
|
|
3034
|
-
body: await parseBody(output.body, context),
|
|
3035
|
-
};
|
|
3036
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
3037
|
-
let errorCode: string = "UnknownError";
|
|
3038
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3039
|
-
switch (errorCode) {
|
|
3040
|
-
case "BadRequest":
|
|
3041
|
-
case "com.amazonaws.efs#BadRequest":
|
|
3042
|
-
response = {
|
|
3043
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
3044
|
-
name: errorCode,
|
|
3045
|
-
$metadata: deserializeMetadata(output),
|
|
3046
|
-
};
|
|
3047
|
-
break;
|
|
3048
|
-
case "FileSystemNotFound":
|
|
3049
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
3050
|
-
response = {
|
|
3051
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
3052
|
-
name: errorCode,
|
|
3053
|
-
$metadata: deserializeMetadata(output),
|
|
3054
|
-
};
|
|
3055
|
-
break;
|
|
3056
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
3057
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
3058
|
-
response = {
|
|
3059
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
3060
|
-
name: errorCode,
|
|
3061
|
-
$metadata: deserializeMetadata(output),
|
|
3062
|
-
};
|
|
3063
|
-
break;
|
|
3064
|
-
case "InternalServerError":
|
|
3065
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
3066
|
-
response = {
|
|
3067
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
3068
|
-
name: errorCode,
|
|
3069
|
-
$metadata: deserializeMetadata(output),
|
|
3070
|
-
};
|
|
3071
|
-
break;
|
|
3072
|
-
default:
|
|
3073
|
-
const parsedBody = parsedOutput.body;
|
|
3074
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3075
|
-
response = {
|
|
3076
|
-
...parsedBody,
|
|
3077
|
-
name: `${errorCode}`,
|
|
3078
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
3079
|
-
$fault: "client",
|
|
3080
|
-
$metadata: deserializeMetadata(output),
|
|
3081
|
-
} as any;
|
|
3082
|
-
}
|
|
3083
|
-
const message = response.message || response.Message || errorCode;
|
|
3084
|
-
response.message = message;
|
|
3085
|
-
delete response.Message;
|
|
3086
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
3087
|
-
};
|
|
3088
|
-
|
|
3089
|
-
export const deserializeAws_restJson1TagResourceCommand = async (
|
|
3090
|
-
output: __HttpResponse,
|
|
3091
|
-
context: __SerdeContext
|
|
3092
|
-
): Promise<TagResourceCommandOutput> => {
|
|
3093
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3094
|
-
return deserializeAws_restJson1TagResourceCommandError(output, context);
|
|
3095
|
-
}
|
|
3096
|
-
const contents: TagResourceCommandOutput = {
|
|
3097
|
-
$metadata: deserializeMetadata(output),
|
|
3098
|
-
};
|
|
3099
|
-
await collectBody(output.body, context);
|
|
3100
|
-
return Promise.resolve(contents);
|
|
3101
|
-
};
|
|
3102
|
-
|
|
3103
|
-
const deserializeAws_restJson1TagResourceCommandError = async (
|
|
3104
|
-
output: __HttpResponse,
|
|
3105
|
-
context: __SerdeContext
|
|
3106
|
-
): Promise<TagResourceCommandOutput> => {
|
|
3107
|
-
const parsedOutput: any = {
|
|
3108
|
-
...output,
|
|
3109
|
-
body: await parseBody(output.body, context),
|
|
3110
|
-
};
|
|
3111
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
3112
|
-
let errorCode: string = "UnknownError";
|
|
3113
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3114
|
-
switch (errorCode) {
|
|
3115
|
-
case "AccessPointNotFound":
|
|
3116
|
-
case "com.amazonaws.efs#AccessPointNotFound":
|
|
3117
|
-
response = {
|
|
3118
|
-
...(await deserializeAws_restJson1AccessPointNotFoundResponse(parsedOutput, context)),
|
|
3119
|
-
name: errorCode,
|
|
3120
|
-
$metadata: deserializeMetadata(output),
|
|
3121
|
-
};
|
|
3122
|
-
break;
|
|
3123
|
-
case "BadRequest":
|
|
3124
|
-
case "com.amazonaws.efs#BadRequest":
|
|
3125
|
-
response = {
|
|
3126
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
3127
|
-
name: errorCode,
|
|
3128
|
-
$metadata: deserializeMetadata(output),
|
|
3129
|
-
};
|
|
3130
|
-
break;
|
|
3131
|
-
case "FileSystemNotFound":
|
|
3132
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
3133
|
-
response = {
|
|
3134
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
3135
|
-
name: errorCode,
|
|
3136
|
-
$metadata: deserializeMetadata(output),
|
|
3137
|
-
};
|
|
3138
|
-
break;
|
|
3139
|
-
case "InternalServerError":
|
|
3140
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
3141
|
-
response = {
|
|
3142
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
3143
|
-
name: errorCode,
|
|
3144
|
-
$metadata: deserializeMetadata(output),
|
|
3145
|
-
};
|
|
3146
|
-
break;
|
|
3147
|
-
default:
|
|
3148
|
-
const parsedBody = parsedOutput.body;
|
|
3149
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3150
|
-
response = {
|
|
3151
|
-
...parsedBody,
|
|
3152
|
-
name: `${errorCode}`,
|
|
3153
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
3154
|
-
$fault: "client",
|
|
3155
|
-
$metadata: deserializeMetadata(output),
|
|
3156
|
-
} as any;
|
|
3157
|
-
}
|
|
3158
|
-
const message = response.message || response.Message || errorCode;
|
|
3159
|
-
response.message = message;
|
|
3160
|
-
delete response.Message;
|
|
3161
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
3162
|
-
};
|
|
3163
|
-
|
|
3164
|
-
export const deserializeAws_restJson1UntagResourceCommand = async (
|
|
3165
|
-
output: __HttpResponse,
|
|
3166
|
-
context: __SerdeContext
|
|
3167
|
-
): Promise<UntagResourceCommandOutput> => {
|
|
3168
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
3169
|
-
return deserializeAws_restJson1UntagResourceCommandError(output, context);
|
|
3170
|
-
}
|
|
3171
|
-
const contents: UntagResourceCommandOutput = {
|
|
3172
|
-
$metadata: deserializeMetadata(output),
|
|
3173
|
-
};
|
|
3174
|
-
await collectBody(output.body, context);
|
|
3175
|
-
return Promise.resolve(contents);
|
|
3176
|
-
};
|
|
3177
|
-
|
|
3178
|
-
const deserializeAws_restJson1UntagResourceCommandError = async (
|
|
3179
|
-
output: __HttpResponse,
|
|
3180
|
-
context: __SerdeContext
|
|
3181
|
-
): Promise<UntagResourceCommandOutput> => {
|
|
3182
|
-
const parsedOutput: any = {
|
|
3183
|
-
...output,
|
|
3184
|
-
body: await parseBody(output.body, context),
|
|
3185
|
-
};
|
|
3186
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
3187
|
-
let errorCode: string = "UnknownError";
|
|
3188
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3189
|
-
switch (errorCode) {
|
|
3190
|
-
case "AccessPointNotFound":
|
|
3191
|
-
case "com.amazonaws.efs#AccessPointNotFound":
|
|
3192
|
-
response = {
|
|
3193
|
-
...(await deserializeAws_restJson1AccessPointNotFoundResponse(parsedOutput, context)),
|
|
3194
|
-
name: errorCode,
|
|
3195
|
-
$metadata: deserializeMetadata(output),
|
|
3196
|
-
};
|
|
3197
|
-
break;
|
|
3198
|
-
case "BadRequest":
|
|
3199
|
-
case "com.amazonaws.efs#BadRequest":
|
|
3200
|
-
response = {
|
|
3201
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
3202
|
-
name: errorCode,
|
|
3203
|
-
$metadata: deserializeMetadata(output),
|
|
3204
|
-
};
|
|
3205
|
-
break;
|
|
3206
|
-
case "FileSystemNotFound":
|
|
3207
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
3208
|
-
response = {
|
|
3209
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
3210
|
-
name: errorCode,
|
|
3211
|
-
$metadata: deserializeMetadata(output),
|
|
3212
|
-
};
|
|
3213
|
-
break;
|
|
3214
|
-
case "InternalServerError":
|
|
3215
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
3216
|
-
response = {
|
|
3217
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
3218
|
-
name: errorCode,
|
|
3219
|
-
$metadata: deserializeMetadata(output),
|
|
3220
|
-
};
|
|
3221
|
-
break;
|
|
3222
|
-
default:
|
|
3223
|
-
const parsedBody = parsedOutput.body;
|
|
3224
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3225
|
-
response = {
|
|
3226
|
-
...parsedBody,
|
|
3227
|
-
name: `${errorCode}`,
|
|
3228
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
3229
|
-
$fault: "client",
|
|
3230
|
-
$metadata: deserializeMetadata(output),
|
|
3231
|
-
} as any;
|
|
3232
|
-
}
|
|
3233
|
-
const message = response.message || response.Message || errorCode;
|
|
3234
|
-
response.message = message;
|
|
3235
|
-
delete response.Message;
|
|
3236
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
3237
|
-
};
|
|
3238
|
-
|
|
3239
|
-
export const deserializeAws_restJson1UpdateFileSystemCommand = async (
|
|
3240
|
-
output: __HttpResponse,
|
|
3241
|
-
context: __SerdeContext
|
|
3242
|
-
): Promise<UpdateFileSystemCommandOutput> => {
|
|
3243
|
-
if (output.statusCode !== 202 && output.statusCode >= 300) {
|
|
3244
|
-
return deserializeAws_restJson1UpdateFileSystemCommandError(output, context);
|
|
3245
|
-
}
|
|
3246
|
-
const contents: UpdateFileSystemCommandOutput = {
|
|
3247
|
-
$metadata: deserializeMetadata(output),
|
|
3248
|
-
AvailabilityZoneId: undefined,
|
|
3249
|
-
AvailabilityZoneName: undefined,
|
|
3250
|
-
CreationTime: undefined,
|
|
3251
|
-
CreationToken: undefined,
|
|
3252
|
-
Encrypted: undefined,
|
|
3253
|
-
FileSystemArn: undefined,
|
|
3254
|
-
FileSystemId: undefined,
|
|
3255
|
-
KmsKeyId: undefined,
|
|
3256
|
-
LifeCycleState: undefined,
|
|
3257
|
-
Name: undefined,
|
|
3258
|
-
NumberOfMountTargets: undefined,
|
|
3259
|
-
OwnerId: undefined,
|
|
3260
|
-
PerformanceMode: undefined,
|
|
3261
|
-
ProvisionedThroughputInMibps: undefined,
|
|
3262
|
-
SizeInBytes: undefined,
|
|
3263
|
-
Tags: undefined,
|
|
3264
|
-
ThroughputMode: undefined,
|
|
3265
|
-
};
|
|
3266
|
-
const data: { [key: string]: any } = __expectNonNull(__expectObject(await parseBody(output.body, context)), "body");
|
|
3267
|
-
if (data.AvailabilityZoneId !== undefined && data.AvailabilityZoneId !== null) {
|
|
3268
|
-
contents.AvailabilityZoneId = __expectString(data.AvailabilityZoneId);
|
|
3269
|
-
}
|
|
3270
|
-
if (data.AvailabilityZoneName !== undefined && data.AvailabilityZoneName !== null) {
|
|
3271
|
-
contents.AvailabilityZoneName = __expectString(data.AvailabilityZoneName);
|
|
3272
|
-
}
|
|
3273
|
-
if (data.CreationTime !== undefined && data.CreationTime !== null) {
|
|
3274
|
-
contents.CreationTime = __expectNonNull(__parseEpochTimestamp(__expectNumber(data.CreationTime)));
|
|
3275
|
-
}
|
|
3276
|
-
if (data.CreationToken !== undefined && data.CreationToken !== null) {
|
|
3277
|
-
contents.CreationToken = __expectString(data.CreationToken);
|
|
3278
|
-
}
|
|
3279
|
-
if (data.Encrypted !== undefined && data.Encrypted !== null) {
|
|
3280
|
-
contents.Encrypted = __expectBoolean(data.Encrypted);
|
|
3281
|
-
}
|
|
3282
|
-
if (data.FileSystemArn !== undefined && data.FileSystemArn !== null) {
|
|
3283
|
-
contents.FileSystemArn = __expectString(data.FileSystemArn);
|
|
3284
|
-
}
|
|
3285
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
3286
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
3287
|
-
}
|
|
3288
|
-
if (data.KmsKeyId !== undefined && data.KmsKeyId !== null) {
|
|
3289
|
-
contents.KmsKeyId = __expectString(data.KmsKeyId);
|
|
3290
|
-
}
|
|
3291
|
-
if (data.LifeCycleState !== undefined && data.LifeCycleState !== null) {
|
|
3292
|
-
contents.LifeCycleState = __expectString(data.LifeCycleState);
|
|
3293
|
-
}
|
|
3294
|
-
if (data.Name !== undefined && data.Name !== null) {
|
|
3295
|
-
contents.Name = __expectString(data.Name);
|
|
3296
|
-
}
|
|
3297
|
-
if (data.NumberOfMountTargets !== undefined && data.NumberOfMountTargets !== null) {
|
|
3298
|
-
contents.NumberOfMountTargets = __expectInt32(data.NumberOfMountTargets);
|
|
3299
|
-
}
|
|
3300
|
-
if (data.OwnerId !== undefined && data.OwnerId !== null) {
|
|
3301
|
-
contents.OwnerId = __expectString(data.OwnerId);
|
|
3302
|
-
}
|
|
3303
|
-
if (data.PerformanceMode !== undefined && data.PerformanceMode !== null) {
|
|
3304
|
-
contents.PerformanceMode = __expectString(data.PerformanceMode);
|
|
3305
|
-
}
|
|
3306
|
-
if (data.ProvisionedThroughputInMibps !== undefined && data.ProvisionedThroughputInMibps !== null) {
|
|
3307
|
-
contents.ProvisionedThroughputInMibps = __limitedParseDouble(data.ProvisionedThroughputInMibps);
|
|
3308
|
-
}
|
|
3309
|
-
if (data.SizeInBytes !== undefined && data.SizeInBytes !== null) {
|
|
3310
|
-
contents.SizeInBytes = deserializeAws_restJson1FileSystemSize(data.SizeInBytes, context);
|
|
3311
|
-
}
|
|
3312
|
-
if (data.Tags !== undefined && data.Tags !== null) {
|
|
3313
|
-
contents.Tags = deserializeAws_restJson1Tags(data.Tags, context);
|
|
3314
|
-
}
|
|
3315
|
-
if (data.ThroughputMode !== undefined && data.ThroughputMode !== null) {
|
|
3316
|
-
contents.ThroughputMode = __expectString(data.ThroughputMode);
|
|
3317
|
-
}
|
|
3318
|
-
return Promise.resolve(contents);
|
|
3319
|
-
};
|
|
3320
|
-
|
|
3321
|
-
const deserializeAws_restJson1UpdateFileSystemCommandError = async (
|
|
3322
|
-
output: __HttpResponse,
|
|
3323
|
-
context: __SerdeContext
|
|
3324
|
-
): Promise<UpdateFileSystemCommandOutput> => {
|
|
3325
|
-
const parsedOutput: any = {
|
|
3326
|
-
...output,
|
|
3327
|
-
body: await parseBody(output.body, context),
|
|
3328
|
-
};
|
|
3329
|
-
let response: __SmithyException & __MetadataBearer & { [key: string]: any };
|
|
3330
|
-
let errorCode: string = "UnknownError";
|
|
3331
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
3332
|
-
switch (errorCode) {
|
|
3333
|
-
case "BadRequest":
|
|
3334
|
-
case "com.amazonaws.efs#BadRequest":
|
|
3335
|
-
response = {
|
|
3336
|
-
...(await deserializeAws_restJson1BadRequestResponse(parsedOutput, context)),
|
|
3337
|
-
name: errorCode,
|
|
3338
|
-
$metadata: deserializeMetadata(output),
|
|
3339
|
-
};
|
|
3340
|
-
break;
|
|
3341
|
-
case "FileSystemNotFound":
|
|
3342
|
-
case "com.amazonaws.efs#FileSystemNotFound":
|
|
3343
|
-
response = {
|
|
3344
|
-
...(await deserializeAws_restJson1FileSystemNotFoundResponse(parsedOutput, context)),
|
|
3345
|
-
name: errorCode,
|
|
3346
|
-
$metadata: deserializeMetadata(output),
|
|
3347
|
-
};
|
|
3348
|
-
break;
|
|
3349
|
-
case "IncorrectFileSystemLifeCycleState":
|
|
3350
|
-
case "com.amazonaws.efs#IncorrectFileSystemLifeCycleState":
|
|
3351
|
-
response = {
|
|
3352
|
-
...(await deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse(parsedOutput, context)),
|
|
3353
|
-
name: errorCode,
|
|
3354
|
-
$metadata: deserializeMetadata(output),
|
|
3355
|
-
};
|
|
3356
|
-
break;
|
|
3357
|
-
case "InsufficientThroughputCapacity":
|
|
3358
|
-
case "com.amazonaws.efs#InsufficientThroughputCapacity":
|
|
3359
|
-
response = {
|
|
3360
|
-
...(await deserializeAws_restJson1InsufficientThroughputCapacityResponse(parsedOutput, context)),
|
|
3361
|
-
name: errorCode,
|
|
3362
|
-
$metadata: deserializeMetadata(output),
|
|
3363
|
-
};
|
|
3364
|
-
break;
|
|
3365
|
-
case "InternalServerError":
|
|
3366
|
-
case "com.amazonaws.efs#InternalServerError":
|
|
3367
|
-
response = {
|
|
3368
|
-
...(await deserializeAws_restJson1InternalServerErrorResponse(parsedOutput, context)),
|
|
3369
|
-
name: errorCode,
|
|
3370
|
-
$metadata: deserializeMetadata(output),
|
|
3371
|
-
};
|
|
3372
|
-
break;
|
|
3373
|
-
case "ThroughputLimitExceeded":
|
|
3374
|
-
case "com.amazonaws.efs#ThroughputLimitExceeded":
|
|
3375
|
-
response = {
|
|
3376
|
-
...(await deserializeAws_restJson1ThroughputLimitExceededResponse(parsedOutput, context)),
|
|
3377
|
-
name: errorCode,
|
|
3378
|
-
$metadata: deserializeMetadata(output),
|
|
3379
|
-
};
|
|
3380
|
-
break;
|
|
3381
|
-
case "TooManyRequests":
|
|
3382
|
-
case "com.amazonaws.efs#TooManyRequests":
|
|
3383
|
-
response = {
|
|
3384
|
-
...(await deserializeAws_restJson1TooManyRequestsResponse(parsedOutput, context)),
|
|
3385
|
-
name: errorCode,
|
|
3386
|
-
$metadata: deserializeMetadata(output),
|
|
3387
|
-
};
|
|
3388
|
-
break;
|
|
3389
|
-
default:
|
|
3390
|
-
const parsedBody = parsedOutput.body;
|
|
3391
|
-
errorCode = parsedBody.code || parsedBody.Code || errorCode;
|
|
3392
|
-
response = {
|
|
3393
|
-
...parsedBody,
|
|
3394
|
-
name: `${errorCode}`,
|
|
3395
|
-
message: parsedBody.message || parsedBody.Message || errorCode,
|
|
3396
|
-
$fault: "client",
|
|
3397
|
-
$metadata: deserializeMetadata(output),
|
|
3398
|
-
} as any;
|
|
3399
|
-
}
|
|
3400
|
-
const message = response.message || response.Message || errorCode;
|
|
3401
|
-
response.message = message;
|
|
3402
|
-
delete response.Message;
|
|
3403
|
-
return Promise.reject(Object.assign(new Error(message), response));
|
|
3404
|
-
};
|
|
3405
|
-
|
|
3406
|
-
const deserializeAws_restJson1AccessPointAlreadyExistsResponse = async (
|
|
3407
|
-
parsedOutput: any,
|
|
3408
|
-
context: __SerdeContext
|
|
3409
|
-
): Promise<AccessPointAlreadyExists> => {
|
|
3410
|
-
const contents: AccessPointAlreadyExists = {
|
|
3411
|
-
name: "AccessPointAlreadyExists",
|
|
3412
|
-
$fault: "client",
|
|
3413
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3414
|
-
AccessPointId: undefined,
|
|
3415
|
-
ErrorCode: undefined,
|
|
3416
|
-
Message: undefined,
|
|
3417
|
-
};
|
|
3418
|
-
const data: any = parsedOutput.body;
|
|
3419
|
-
if (data.AccessPointId !== undefined && data.AccessPointId !== null) {
|
|
3420
|
-
contents.AccessPointId = __expectString(data.AccessPointId);
|
|
3421
|
-
}
|
|
3422
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3423
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3424
|
-
}
|
|
3425
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3426
|
-
contents.Message = __expectString(data.Message);
|
|
3427
|
-
}
|
|
3428
|
-
return contents;
|
|
3429
|
-
};
|
|
3430
|
-
|
|
3431
|
-
const deserializeAws_restJson1AccessPointLimitExceededResponse = async (
|
|
3432
|
-
parsedOutput: any,
|
|
3433
|
-
context: __SerdeContext
|
|
3434
|
-
): Promise<AccessPointLimitExceeded> => {
|
|
3435
|
-
const contents: AccessPointLimitExceeded = {
|
|
3436
|
-
name: "AccessPointLimitExceeded",
|
|
3437
|
-
$fault: "client",
|
|
3438
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3439
|
-
ErrorCode: undefined,
|
|
3440
|
-
Message: undefined,
|
|
3441
|
-
};
|
|
3442
|
-
const data: any = parsedOutput.body;
|
|
3443
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3444
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3445
|
-
}
|
|
3446
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3447
|
-
contents.Message = __expectString(data.Message);
|
|
3448
|
-
}
|
|
3449
|
-
return contents;
|
|
3450
|
-
};
|
|
3451
|
-
|
|
3452
|
-
const deserializeAws_restJson1AccessPointNotFoundResponse = async (
|
|
3453
|
-
parsedOutput: any,
|
|
3454
|
-
context: __SerdeContext
|
|
3455
|
-
): Promise<AccessPointNotFound> => {
|
|
3456
|
-
const contents: AccessPointNotFound = {
|
|
3457
|
-
name: "AccessPointNotFound",
|
|
3458
|
-
$fault: "client",
|
|
3459
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3460
|
-
ErrorCode: undefined,
|
|
3461
|
-
Message: undefined,
|
|
3462
|
-
};
|
|
3463
|
-
const data: any = parsedOutput.body;
|
|
3464
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3465
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3466
|
-
}
|
|
3467
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3468
|
-
contents.Message = __expectString(data.Message);
|
|
3469
|
-
}
|
|
3470
|
-
return contents;
|
|
3471
|
-
};
|
|
3472
|
-
|
|
3473
|
-
const deserializeAws_restJson1AvailabilityZonesMismatchResponse = async (
|
|
3474
|
-
parsedOutput: any,
|
|
3475
|
-
context: __SerdeContext
|
|
3476
|
-
): Promise<AvailabilityZonesMismatch> => {
|
|
3477
|
-
const contents: AvailabilityZonesMismatch = {
|
|
3478
|
-
name: "AvailabilityZonesMismatch",
|
|
3479
|
-
$fault: "client",
|
|
3480
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3481
|
-
ErrorCode: undefined,
|
|
3482
|
-
Message: undefined,
|
|
3483
|
-
};
|
|
3484
|
-
const data: any = parsedOutput.body;
|
|
3485
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3486
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3487
|
-
}
|
|
3488
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3489
|
-
contents.Message = __expectString(data.Message);
|
|
3490
|
-
}
|
|
3491
|
-
return contents;
|
|
3492
|
-
};
|
|
3493
|
-
|
|
3494
|
-
const deserializeAws_restJson1BadRequestResponse = async (
|
|
3495
|
-
parsedOutput: any,
|
|
3496
|
-
context: __SerdeContext
|
|
3497
|
-
): Promise<BadRequest> => {
|
|
3498
|
-
const contents: BadRequest = {
|
|
3499
|
-
name: "BadRequest",
|
|
3500
|
-
$fault: "client",
|
|
3501
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3502
|
-
ErrorCode: undefined,
|
|
3503
|
-
Message: undefined,
|
|
3504
|
-
};
|
|
3505
|
-
const data: any = parsedOutput.body;
|
|
3506
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3507
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3508
|
-
}
|
|
3509
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3510
|
-
contents.Message = __expectString(data.Message);
|
|
3511
|
-
}
|
|
3512
|
-
return contents;
|
|
3513
|
-
};
|
|
3514
|
-
|
|
3515
|
-
const deserializeAws_restJson1DependencyTimeoutResponse = async (
|
|
3516
|
-
parsedOutput: any,
|
|
3517
|
-
context: __SerdeContext
|
|
3518
|
-
): Promise<DependencyTimeout> => {
|
|
3519
|
-
const contents: DependencyTimeout = {
|
|
3520
|
-
name: "DependencyTimeout",
|
|
3521
|
-
$fault: "server",
|
|
3522
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3523
|
-
ErrorCode: undefined,
|
|
3524
|
-
Message: undefined,
|
|
3525
|
-
};
|
|
3526
|
-
const data: any = parsedOutput.body;
|
|
3527
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3528
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3529
|
-
}
|
|
3530
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3531
|
-
contents.Message = __expectString(data.Message);
|
|
3532
|
-
}
|
|
3533
|
-
return contents;
|
|
3534
|
-
};
|
|
3535
|
-
|
|
3536
|
-
const deserializeAws_restJson1FileSystemAlreadyExistsResponse = async (
|
|
3537
|
-
parsedOutput: any,
|
|
3538
|
-
context: __SerdeContext
|
|
3539
|
-
): Promise<FileSystemAlreadyExists> => {
|
|
3540
|
-
const contents: FileSystemAlreadyExists = {
|
|
3541
|
-
name: "FileSystemAlreadyExists",
|
|
3542
|
-
$fault: "client",
|
|
3543
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3544
|
-
ErrorCode: undefined,
|
|
3545
|
-
FileSystemId: undefined,
|
|
3546
|
-
Message: undefined,
|
|
3547
|
-
};
|
|
3548
|
-
const data: any = parsedOutput.body;
|
|
3549
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3550
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3551
|
-
}
|
|
3552
|
-
if (data.FileSystemId !== undefined && data.FileSystemId !== null) {
|
|
3553
|
-
contents.FileSystemId = __expectString(data.FileSystemId);
|
|
3554
|
-
}
|
|
3555
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3556
|
-
contents.Message = __expectString(data.Message);
|
|
3557
|
-
}
|
|
3558
|
-
return contents;
|
|
3559
|
-
};
|
|
3560
|
-
|
|
3561
|
-
const deserializeAws_restJson1FileSystemInUseResponse = async (
|
|
3562
|
-
parsedOutput: any,
|
|
3563
|
-
context: __SerdeContext
|
|
3564
|
-
): Promise<FileSystemInUse> => {
|
|
3565
|
-
const contents: FileSystemInUse = {
|
|
3566
|
-
name: "FileSystemInUse",
|
|
3567
|
-
$fault: "client",
|
|
3568
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3569
|
-
ErrorCode: undefined,
|
|
3570
|
-
Message: undefined,
|
|
3571
|
-
};
|
|
3572
|
-
const data: any = parsedOutput.body;
|
|
3573
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3574
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3575
|
-
}
|
|
3576
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3577
|
-
contents.Message = __expectString(data.Message);
|
|
3578
|
-
}
|
|
3579
|
-
return contents;
|
|
3580
|
-
};
|
|
3581
|
-
|
|
3582
|
-
const deserializeAws_restJson1FileSystemLimitExceededResponse = async (
|
|
3583
|
-
parsedOutput: any,
|
|
3584
|
-
context: __SerdeContext
|
|
3585
|
-
): Promise<FileSystemLimitExceeded> => {
|
|
3586
|
-
const contents: FileSystemLimitExceeded = {
|
|
3587
|
-
name: "FileSystemLimitExceeded",
|
|
3588
|
-
$fault: "client",
|
|
3589
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3590
|
-
ErrorCode: undefined,
|
|
3591
|
-
Message: undefined,
|
|
3592
|
-
};
|
|
3593
|
-
const data: any = parsedOutput.body;
|
|
3594
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3595
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3596
|
-
}
|
|
3597
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3598
|
-
contents.Message = __expectString(data.Message);
|
|
3599
|
-
}
|
|
3600
|
-
return contents;
|
|
3601
|
-
};
|
|
3602
|
-
|
|
3603
|
-
const deserializeAws_restJson1FileSystemNotFoundResponse = async (
|
|
3604
|
-
parsedOutput: any,
|
|
3605
|
-
context: __SerdeContext
|
|
3606
|
-
): Promise<FileSystemNotFound> => {
|
|
3607
|
-
const contents: FileSystemNotFound = {
|
|
3608
|
-
name: "FileSystemNotFound",
|
|
3609
|
-
$fault: "client",
|
|
3610
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3611
|
-
ErrorCode: undefined,
|
|
3612
|
-
Message: undefined,
|
|
3613
|
-
};
|
|
3614
|
-
const data: any = parsedOutput.body;
|
|
3615
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3616
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3617
|
-
}
|
|
3618
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3619
|
-
contents.Message = __expectString(data.Message);
|
|
3620
|
-
}
|
|
3621
|
-
return contents;
|
|
3622
|
-
};
|
|
3623
|
-
|
|
3624
|
-
const deserializeAws_restJson1IncorrectFileSystemLifeCycleStateResponse = async (
|
|
3625
|
-
parsedOutput: any,
|
|
3626
|
-
context: __SerdeContext
|
|
3627
|
-
): Promise<IncorrectFileSystemLifeCycleState> => {
|
|
3628
|
-
const contents: IncorrectFileSystemLifeCycleState = {
|
|
3629
|
-
name: "IncorrectFileSystemLifeCycleState",
|
|
3630
|
-
$fault: "client",
|
|
3631
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3632
|
-
ErrorCode: undefined,
|
|
3633
|
-
Message: undefined,
|
|
3634
|
-
};
|
|
3635
|
-
const data: any = parsedOutput.body;
|
|
3636
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3637
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3638
|
-
}
|
|
3639
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3640
|
-
contents.Message = __expectString(data.Message);
|
|
3641
|
-
}
|
|
3642
|
-
return contents;
|
|
3643
|
-
};
|
|
3644
|
-
|
|
3645
|
-
const deserializeAws_restJson1IncorrectMountTargetStateResponse = async (
|
|
3646
|
-
parsedOutput: any,
|
|
3647
|
-
context: __SerdeContext
|
|
3648
|
-
): Promise<IncorrectMountTargetState> => {
|
|
3649
|
-
const contents: IncorrectMountTargetState = {
|
|
3650
|
-
name: "IncorrectMountTargetState",
|
|
3651
|
-
$fault: "client",
|
|
3652
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3653
|
-
ErrorCode: undefined,
|
|
3654
|
-
Message: undefined,
|
|
3655
|
-
};
|
|
3656
|
-
const data: any = parsedOutput.body;
|
|
3657
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3658
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3659
|
-
}
|
|
3660
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3661
|
-
contents.Message = __expectString(data.Message);
|
|
3662
|
-
}
|
|
3663
|
-
return contents;
|
|
3664
|
-
};
|
|
3665
|
-
|
|
3666
|
-
const deserializeAws_restJson1InsufficientThroughputCapacityResponse = async (
|
|
3667
|
-
parsedOutput: any,
|
|
3668
|
-
context: __SerdeContext
|
|
3669
|
-
): Promise<InsufficientThroughputCapacity> => {
|
|
3670
|
-
const contents: InsufficientThroughputCapacity = {
|
|
3671
|
-
name: "InsufficientThroughputCapacity",
|
|
3672
|
-
$fault: "server",
|
|
3673
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3674
|
-
ErrorCode: undefined,
|
|
3675
|
-
Message: undefined,
|
|
3676
|
-
};
|
|
3677
|
-
const data: any = parsedOutput.body;
|
|
3678
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3679
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3680
|
-
}
|
|
3681
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3682
|
-
contents.Message = __expectString(data.Message);
|
|
3683
|
-
}
|
|
3684
|
-
return contents;
|
|
3685
|
-
};
|
|
3686
|
-
|
|
3687
|
-
const deserializeAws_restJson1InternalServerErrorResponse = async (
|
|
3688
|
-
parsedOutput: any,
|
|
3689
|
-
context: __SerdeContext
|
|
3690
|
-
): Promise<InternalServerError> => {
|
|
3691
|
-
const contents: InternalServerError = {
|
|
3692
|
-
name: "InternalServerError",
|
|
3693
|
-
$fault: "server",
|
|
3694
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3695
|
-
ErrorCode: undefined,
|
|
3696
|
-
Message: undefined,
|
|
3697
|
-
};
|
|
3698
|
-
const data: any = parsedOutput.body;
|
|
3699
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3700
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3701
|
-
}
|
|
3702
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3703
|
-
contents.Message = __expectString(data.Message);
|
|
3704
|
-
}
|
|
3705
|
-
return contents;
|
|
3706
|
-
};
|
|
3707
|
-
|
|
3708
|
-
const deserializeAws_restJson1InvalidPolicyExceptionResponse = async (
|
|
3709
|
-
parsedOutput: any,
|
|
3710
|
-
context: __SerdeContext
|
|
3711
|
-
): Promise<InvalidPolicyException> => {
|
|
3712
|
-
const contents: InvalidPolicyException = {
|
|
3713
|
-
name: "InvalidPolicyException",
|
|
3714
|
-
$fault: "client",
|
|
3715
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3716
|
-
ErrorCode: undefined,
|
|
3717
|
-
Message: undefined,
|
|
3718
|
-
};
|
|
3719
|
-
const data: any = parsedOutput.body;
|
|
3720
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3721
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3722
|
-
}
|
|
3723
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3724
|
-
contents.Message = __expectString(data.Message);
|
|
3725
|
-
}
|
|
3726
|
-
return contents;
|
|
3727
|
-
};
|
|
3728
|
-
|
|
3729
|
-
const deserializeAws_restJson1IpAddressInUseResponse = async (
|
|
3730
|
-
parsedOutput: any,
|
|
3731
|
-
context: __SerdeContext
|
|
3732
|
-
): Promise<IpAddressInUse> => {
|
|
3733
|
-
const contents: IpAddressInUse = {
|
|
3734
|
-
name: "IpAddressInUse",
|
|
3735
|
-
$fault: "client",
|
|
3736
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3737
|
-
ErrorCode: undefined,
|
|
3738
|
-
Message: undefined,
|
|
3739
|
-
};
|
|
3740
|
-
const data: any = parsedOutput.body;
|
|
3741
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3742
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3743
|
-
}
|
|
3744
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3745
|
-
contents.Message = __expectString(data.Message);
|
|
3746
|
-
}
|
|
3747
|
-
return contents;
|
|
3748
|
-
};
|
|
3749
|
-
|
|
3750
|
-
const deserializeAws_restJson1MountTargetConflictResponse = async (
|
|
3751
|
-
parsedOutput: any,
|
|
3752
|
-
context: __SerdeContext
|
|
3753
|
-
): Promise<MountTargetConflict> => {
|
|
3754
|
-
const contents: MountTargetConflict = {
|
|
3755
|
-
name: "MountTargetConflict",
|
|
3756
|
-
$fault: "client",
|
|
3757
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3758
|
-
ErrorCode: undefined,
|
|
3759
|
-
Message: undefined,
|
|
3760
|
-
};
|
|
3761
|
-
const data: any = parsedOutput.body;
|
|
3762
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3763
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3764
|
-
}
|
|
3765
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3766
|
-
contents.Message = __expectString(data.Message);
|
|
3767
|
-
}
|
|
3768
|
-
return contents;
|
|
3769
|
-
};
|
|
3770
|
-
|
|
3771
|
-
const deserializeAws_restJson1MountTargetNotFoundResponse = async (
|
|
3772
|
-
parsedOutput: any,
|
|
3773
|
-
context: __SerdeContext
|
|
3774
|
-
): Promise<MountTargetNotFound> => {
|
|
3775
|
-
const contents: MountTargetNotFound = {
|
|
3776
|
-
name: "MountTargetNotFound",
|
|
3777
|
-
$fault: "client",
|
|
3778
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3779
|
-
ErrorCode: undefined,
|
|
3780
|
-
Message: undefined,
|
|
3781
|
-
};
|
|
3782
|
-
const data: any = parsedOutput.body;
|
|
3783
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3784
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3785
|
-
}
|
|
3786
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3787
|
-
contents.Message = __expectString(data.Message);
|
|
3788
|
-
}
|
|
3789
|
-
return contents;
|
|
3790
|
-
};
|
|
3791
|
-
|
|
3792
|
-
const deserializeAws_restJson1NetworkInterfaceLimitExceededResponse = async (
|
|
3793
|
-
parsedOutput: any,
|
|
3794
|
-
context: __SerdeContext
|
|
3795
|
-
): Promise<NetworkInterfaceLimitExceeded> => {
|
|
3796
|
-
const contents: NetworkInterfaceLimitExceeded = {
|
|
3797
|
-
name: "NetworkInterfaceLimitExceeded",
|
|
3798
|
-
$fault: "client",
|
|
3799
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3800
|
-
ErrorCode: undefined,
|
|
3801
|
-
Message: undefined,
|
|
3802
|
-
};
|
|
3803
|
-
const data: any = parsedOutput.body;
|
|
3804
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3805
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3806
|
-
}
|
|
3807
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3808
|
-
contents.Message = __expectString(data.Message);
|
|
3809
|
-
}
|
|
3810
|
-
return contents;
|
|
3811
|
-
};
|
|
3812
|
-
|
|
3813
|
-
const deserializeAws_restJson1NoFreeAddressesInSubnetResponse = async (
|
|
3814
|
-
parsedOutput: any,
|
|
3815
|
-
context: __SerdeContext
|
|
3816
|
-
): Promise<NoFreeAddressesInSubnet> => {
|
|
3817
|
-
const contents: NoFreeAddressesInSubnet = {
|
|
3818
|
-
name: "NoFreeAddressesInSubnet",
|
|
3819
|
-
$fault: "client",
|
|
3820
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3821
|
-
ErrorCode: undefined,
|
|
3822
|
-
Message: undefined,
|
|
3823
|
-
};
|
|
3824
|
-
const data: any = parsedOutput.body;
|
|
3825
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3826
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3827
|
-
}
|
|
3828
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3829
|
-
contents.Message = __expectString(data.Message);
|
|
3830
|
-
}
|
|
3831
|
-
return contents;
|
|
3832
|
-
};
|
|
3833
|
-
|
|
3834
|
-
const deserializeAws_restJson1PolicyNotFoundResponse = async (
|
|
3835
|
-
parsedOutput: any,
|
|
3836
|
-
context: __SerdeContext
|
|
3837
|
-
): Promise<PolicyNotFound> => {
|
|
3838
|
-
const contents: PolicyNotFound = {
|
|
3839
|
-
name: "PolicyNotFound",
|
|
3840
|
-
$fault: "client",
|
|
3841
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3842
|
-
ErrorCode: undefined,
|
|
3843
|
-
Message: undefined,
|
|
3844
|
-
};
|
|
3845
|
-
const data: any = parsedOutput.body;
|
|
3846
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3847
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3848
|
-
}
|
|
3849
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3850
|
-
contents.Message = __expectString(data.Message);
|
|
3851
|
-
}
|
|
3852
|
-
return contents;
|
|
3853
|
-
};
|
|
3854
|
-
|
|
3855
|
-
const deserializeAws_restJson1SecurityGroupLimitExceededResponse = async (
|
|
3856
|
-
parsedOutput: any,
|
|
3857
|
-
context: __SerdeContext
|
|
3858
|
-
): Promise<SecurityGroupLimitExceeded> => {
|
|
3859
|
-
const contents: SecurityGroupLimitExceeded = {
|
|
3860
|
-
name: "SecurityGroupLimitExceeded",
|
|
3861
|
-
$fault: "client",
|
|
3862
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3863
|
-
ErrorCode: undefined,
|
|
3864
|
-
Message: undefined,
|
|
3865
|
-
};
|
|
3866
|
-
const data: any = parsedOutput.body;
|
|
3867
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3868
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3869
|
-
}
|
|
3870
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3871
|
-
contents.Message = __expectString(data.Message);
|
|
3872
|
-
}
|
|
3873
|
-
return contents;
|
|
3874
|
-
};
|
|
3875
|
-
|
|
3876
|
-
const deserializeAws_restJson1SecurityGroupNotFoundResponse = async (
|
|
3877
|
-
parsedOutput: any,
|
|
3878
|
-
context: __SerdeContext
|
|
3879
|
-
): Promise<SecurityGroupNotFound> => {
|
|
3880
|
-
const contents: SecurityGroupNotFound = {
|
|
3881
|
-
name: "SecurityGroupNotFound",
|
|
3882
|
-
$fault: "client",
|
|
3883
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3884
|
-
ErrorCode: undefined,
|
|
3885
|
-
Message: undefined,
|
|
3886
|
-
};
|
|
3887
|
-
const data: any = parsedOutput.body;
|
|
3888
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3889
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3890
|
-
}
|
|
3891
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3892
|
-
contents.Message = __expectString(data.Message);
|
|
3893
|
-
}
|
|
3894
|
-
return contents;
|
|
3895
|
-
};
|
|
3896
|
-
|
|
3897
|
-
const deserializeAws_restJson1SubnetNotFoundResponse = async (
|
|
3898
|
-
parsedOutput: any,
|
|
3899
|
-
context: __SerdeContext
|
|
3900
|
-
): Promise<SubnetNotFound> => {
|
|
3901
|
-
const contents: SubnetNotFound = {
|
|
3902
|
-
name: "SubnetNotFound",
|
|
3903
|
-
$fault: "client",
|
|
3904
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3905
|
-
ErrorCode: undefined,
|
|
3906
|
-
Message: undefined,
|
|
3907
|
-
};
|
|
3908
|
-
const data: any = parsedOutput.body;
|
|
3909
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3910
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3911
|
-
}
|
|
3912
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3913
|
-
contents.Message = __expectString(data.Message);
|
|
3914
|
-
}
|
|
3915
|
-
return contents;
|
|
3916
|
-
};
|
|
3917
|
-
|
|
3918
|
-
const deserializeAws_restJson1ThroughputLimitExceededResponse = async (
|
|
3919
|
-
parsedOutput: any,
|
|
3920
|
-
context: __SerdeContext
|
|
3921
|
-
): Promise<ThroughputLimitExceeded> => {
|
|
3922
|
-
const contents: ThroughputLimitExceeded = {
|
|
3923
|
-
name: "ThroughputLimitExceeded",
|
|
3924
|
-
$fault: "client",
|
|
3925
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3926
|
-
ErrorCode: undefined,
|
|
3927
|
-
Message: undefined,
|
|
3928
|
-
};
|
|
3929
|
-
const data: any = parsedOutput.body;
|
|
3930
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3931
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3932
|
-
}
|
|
3933
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3934
|
-
contents.Message = __expectString(data.Message);
|
|
3935
|
-
}
|
|
3936
|
-
return contents;
|
|
3937
|
-
};
|
|
3938
|
-
|
|
3939
|
-
const deserializeAws_restJson1TooManyRequestsResponse = async (
|
|
3940
|
-
parsedOutput: any,
|
|
3941
|
-
context: __SerdeContext
|
|
3942
|
-
): Promise<TooManyRequests> => {
|
|
3943
|
-
const contents: TooManyRequests = {
|
|
3944
|
-
name: "TooManyRequests",
|
|
3945
|
-
$fault: "client",
|
|
3946
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3947
|
-
ErrorCode: undefined,
|
|
3948
|
-
Message: undefined,
|
|
3949
|
-
};
|
|
3950
|
-
const data: any = parsedOutput.body;
|
|
3951
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3952
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3953
|
-
}
|
|
3954
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3955
|
-
contents.Message = __expectString(data.Message);
|
|
3956
|
-
}
|
|
3957
|
-
return contents;
|
|
3958
|
-
};
|
|
3959
|
-
|
|
3960
|
-
const deserializeAws_restJson1UnsupportedAvailabilityZoneResponse = async (
|
|
3961
|
-
parsedOutput: any,
|
|
3962
|
-
context: __SerdeContext
|
|
3963
|
-
): Promise<UnsupportedAvailabilityZone> => {
|
|
3964
|
-
const contents: UnsupportedAvailabilityZone = {
|
|
3965
|
-
name: "UnsupportedAvailabilityZone",
|
|
3966
|
-
$fault: "client",
|
|
3967
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3968
|
-
ErrorCode: undefined,
|
|
3969
|
-
Message: undefined,
|
|
3970
|
-
};
|
|
3971
|
-
const data: any = parsedOutput.body;
|
|
3972
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3973
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3974
|
-
}
|
|
3975
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3976
|
-
contents.Message = __expectString(data.Message);
|
|
3977
|
-
}
|
|
3978
|
-
return contents;
|
|
3979
|
-
};
|
|
3980
|
-
|
|
3981
|
-
const deserializeAws_restJson1ValidationExceptionResponse = async (
|
|
3982
|
-
parsedOutput: any,
|
|
3983
|
-
context: __SerdeContext
|
|
3984
|
-
): Promise<ValidationException> => {
|
|
3985
|
-
const contents: ValidationException = {
|
|
3986
|
-
name: "ValidationException",
|
|
3987
|
-
$fault: "client",
|
|
3988
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
3989
|
-
ErrorCode: undefined,
|
|
3990
|
-
Message: undefined,
|
|
3991
|
-
};
|
|
3992
|
-
const data: any = parsedOutput.body;
|
|
3993
|
-
if (data.ErrorCode !== undefined && data.ErrorCode !== null) {
|
|
3994
|
-
contents.ErrorCode = __expectString(data.ErrorCode);
|
|
3995
|
-
}
|
|
3996
|
-
if (data.Message !== undefined && data.Message !== null) {
|
|
3997
|
-
contents.Message = __expectString(data.Message);
|
|
3998
|
-
}
|
|
3999
|
-
return contents;
|
|
4000
|
-
};
|
|
4001
|
-
|
|
4002
|
-
const serializeAws_restJson1BackupPolicy = (input: BackupPolicy, context: __SerdeContext): any => {
|
|
4003
|
-
return {
|
|
4004
|
-
...(input.Status !== undefined && input.Status !== null && { Status: input.Status }),
|
|
4005
|
-
};
|
|
4006
|
-
};
|
|
4007
|
-
|
|
4008
|
-
const serializeAws_restJson1CreationInfo = (input: CreationInfo, context: __SerdeContext): any => {
|
|
4009
|
-
return {
|
|
4010
|
-
...(input.OwnerGid !== undefined && input.OwnerGid !== null && { OwnerGid: input.OwnerGid }),
|
|
4011
|
-
...(input.OwnerUid !== undefined && input.OwnerUid !== null && { OwnerUid: input.OwnerUid }),
|
|
4012
|
-
...(input.Permissions !== undefined && input.Permissions !== null && { Permissions: input.Permissions }),
|
|
4013
|
-
};
|
|
4014
|
-
};
|
|
4015
|
-
|
|
4016
|
-
const serializeAws_restJson1LifecyclePolicies = (input: LifecyclePolicy[], context: __SerdeContext): any => {
|
|
4017
|
-
return input
|
|
4018
|
-
.filter((e: any) => e != null)
|
|
4019
|
-
.map((entry) => {
|
|
4020
|
-
if (entry === null) {
|
|
4021
|
-
return null as any;
|
|
4022
|
-
}
|
|
4023
|
-
return serializeAws_restJson1LifecyclePolicy(entry, context);
|
|
4024
|
-
});
|
|
4025
|
-
};
|
|
4026
|
-
|
|
4027
|
-
const serializeAws_restJson1LifecyclePolicy = (input: LifecyclePolicy, context: __SerdeContext): any => {
|
|
4028
|
-
return {
|
|
4029
|
-
...(input.TransitionToIA !== undefined &&
|
|
4030
|
-
input.TransitionToIA !== null && { TransitionToIA: input.TransitionToIA }),
|
|
4031
|
-
...(input.TransitionToPrimaryStorageClass !== undefined &&
|
|
4032
|
-
input.TransitionToPrimaryStorageClass !== null && {
|
|
4033
|
-
TransitionToPrimaryStorageClass: input.TransitionToPrimaryStorageClass,
|
|
4034
|
-
}),
|
|
4035
|
-
};
|
|
4036
|
-
};
|
|
4037
|
-
|
|
4038
|
-
const serializeAws_restJson1PosixUser = (input: PosixUser, context: __SerdeContext): any => {
|
|
4039
|
-
return {
|
|
4040
|
-
...(input.Gid !== undefined && input.Gid !== null && { Gid: input.Gid }),
|
|
4041
|
-
...(input.SecondaryGids !== undefined &&
|
|
4042
|
-
input.SecondaryGids !== null && {
|
|
4043
|
-
SecondaryGids: serializeAws_restJson1SecondaryGids(input.SecondaryGids, context),
|
|
4044
|
-
}),
|
|
4045
|
-
...(input.Uid !== undefined && input.Uid !== null && { Uid: input.Uid }),
|
|
4046
|
-
};
|
|
4047
|
-
};
|
|
4048
|
-
|
|
4049
|
-
const serializeAws_restJson1RootDirectory = (input: RootDirectory, context: __SerdeContext): any => {
|
|
4050
|
-
return {
|
|
4051
|
-
...(input.CreationInfo !== undefined &&
|
|
4052
|
-
input.CreationInfo !== null && { CreationInfo: serializeAws_restJson1CreationInfo(input.CreationInfo, context) }),
|
|
4053
|
-
...(input.Path !== undefined && input.Path !== null && { Path: input.Path }),
|
|
4054
|
-
};
|
|
4055
|
-
};
|
|
4056
|
-
|
|
4057
|
-
const serializeAws_restJson1SecondaryGids = (input: number[], context: __SerdeContext): any => {
|
|
4058
|
-
return input
|
|
4059
|
-
.filter((e: any) => e != null)
|
|
4060
|
-
.map((entry) => {
|
|
4061
|
-
if (entry === null) {
|
|
4062
|
-
return null as any;
|
|
4063
|
-
}
|
|
4064
|
-
return entry;
|
|
4065
|
-
});
|
|
4066
|
-
};
|
|
4067
|
-
|
|
4068
|
-
const serializeAws_restJson1SecurityGroups = (input: string[], context: __SerdeContext): any => {
|
|
4069
|
-
return input
|
|
4070
|
-
.filter((e: any) => e != null)
|
|
4071
|
-
.map((entry) => {
|
|
4072
|
-
if (entry === null) {
|
|
4073
|
-
return null as any;
|
|
4074
|
-
}
|
|
4075
|
-
return entry;
|
|
4076
|
-
});
|
|
4077
|
-
};
|
|
4078
|
-
|
|
4079
|
-
const serializeAws_restJson1Tag = (input: Tag, context: __SerdeContext): any => {
|
|
4080
|
-
return {
|
|
4081
|
-
...(input.Key !== undefined && input.Key !== null && { Key: input.Key }),
|
|
4082
|
-
...(input.Value !== undefined && input.Value !== null && { Value: input.Value }),
|
|
4083
|
-
};
|
|
4084
|
-
};
|
|
4085
|
-
|
|
4086
|
-
const serializeAws_restJson1TagKeys = (input: string[], context: __SerdeContext): any => {
|
|
4087
|
-
return input
|
|
4088
|
-
.filter((e: any) => e != null)
|
|
4089
|
-
.map((entry) => {
|
|
4090
|
-
if (entry === null) {
|
|
4091
|
-
return null as any;
|
|
4092
|
-
}
|
|
4093
|
-
return entry;
|
|
4094
|
-
});
|
|
4095
|
-
};
|
|
4096
|
-
|
|
4097
|
-
const serializeAws_restJson1Tags = (input: Tag[], context: __SerdeContext): any => {
|
|
4098
|
-
return input
|
|
4099
|
-
.filter((e: any) => e != null)
|
|
4100
|
-
.map((entry) => {
|
|
4101
|
-
if (entry === null) {
|
|
4102
|
-
return null as any;
|
|
4103
|
-
}
|
|
4104
|
-
return serializeAws_restJson1Tag(entry, context);
|
|
4105
|
-
});
|
|
4106
|
-
};
|
|
4107
|
-
|
|
4108
|
-
const deserializeAws_restJson1AccessPointDescription = (
|
|
4109
|
-
output: any,
|
|
4110
|
-
context: __SerdeContext
|
|
4111
|
-
): AccessPointDescription => {
|
|
4112
|
-
return {
|
|
4113
|
-
AccessPointArn: __expectString(output.AccessPointArn),
|
|
4114
|
-
AccessPointId: __expectString(output.AccessPointId),
|
|
4115
|
-
ClientToken: __expectString(output.ClientToken),
|
|
4116
|
-
FileSystemId: __expectString(output.FileSystemId),
|
|
4117
|
-
LifeCycleState: __expectString(output.LifeCycleState),
|
|
4118
|
-
Name: __expectString(output.Name),
|
|
4119
|
-
OwnerId: __expectString(output.OwnerId),
|
|
4120
|
-
PosixUser:
|
|
4121
|
-
output.PosixUser !== undefined && output.PosixUser !== null
|
|
4122
|
-
? deserializeAws_restJson1PosixUser(output.PosixUser, context)
|
|
4123
|
-
: undefined,
|
|
4124
|
-
RootDirectory:
|
|
4125
|
-
output.RootDirectory !== undefined && output.RootDirectory !== null
|
|
4126
|
-
? deserializeAws_restJson1RootDirectory(output.RootDirectory, context)
|
|
4127
|
-
: undefined,
|
|
4128
|
-
Tags:
|
|
4129
|
-
output.Tags !== undefined && output.Tags !== null
|
|
4130
|
-
? deserializeAws_restJson1Tags(output.Tags, context)
|
|
4131
|
-
: undefined,
|
|
4132
|
-
} as any;
|
|
4133
|
-
};
|
|
4134
|
-
|
|
4135
|
-
const deserializeAws_restJson1AccessPointDescriptions = (
|
|
4136
|
-
output: any,
|
|
4137
|
-
context: __SerdeContext
|
|
4138
|
-
): AccessPointDescription[] => {
|
|
4139
|
-
return (output || [])
|
|
4140
|
-
.filter((e: any) => e != null)
|
|
4141
|
-
.map((entry: any) => {
|
|
4142
|
-
if (entry === null) {
|
|
4143
|
-
return null as any;
|
|
4144
|
-
}
|
|
4145
|
-
return deserializeAws_restJson1AccessPointDescription(entry, context);
|
|
4146
|
-
});
|
|
4147
|
-
};
|
|
4148
|
-
|
|
4149
|
-
const deserializeAws_restJson1BackupPolicy = (output: any, context: __SerdeContext): BackupPolicy => {
|
|
4150
|
-
return {
|
|
4151
|
-
Status: __expectString(output.Status),
|
|
4152
|
-
} as any;
|
|
4153
|
-
};
|
|
4154
|
-
|
|
4155
|
-
const deserializeAws_restJson1CreationInfo = (output: any, context: __SerdeContext): CreationInfo => {
|
|
4156
|
-
return {
|
|
4157
|
-
OwnerGid: __expectLong(output.OwnerGid),
|
|
4158
|
-
OwnerUid: __expectLong(output.OwnerUid),
|
|
4159
|
-
Permissions: __expectString(output.Permissions),
|
|
4160
|
-
} as any;
|
|
4161
|
-
};
|
|
4162
|
-
|
|
4163
|
-
const deserializeAws_restJson1FileSystemDescription = (output: any, context: __SerdeContext): FileSystemDescription => {
|
|
4164
|
-
return {
|
|
4165
|
-
AvailabilityZoneId: __expectString(output.AvailabilityZoneId),
|
|
4166
|
-
AvailabilityZoneName: __expectString(output.AvailabilityZoneName),
|
|
4167
|
-
CreationTime:
|
|
4168
|
-
output.CreationTime !== undefined && output.CreationTime !== null
|
|
4169
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreationTime)))
|
|
4170
|
-
: undefined,
|
|
4171
|
-
CreationToken: __expectString(output.CreationToken),
|
|
4172
|
-
Encrypted: __expectBoolean(output.Encrypted),
|
|
4173
|
-
FileSystemArn: __expectString(output.FileSystemArn),
|
|
4174
|
-
FileSystemId: __expectString(output.FileSystemId),
|
|
4175
|
-
KmsKeyId: __expectString(output.KmsKeyId),
|
|
4176
|
-
LifeCycleState: __expectString(output.LifeCycleState),
|
|
4177
|
-
Name: __expectString(output.Name),
|
|
4178
|
-
NumberOfMountTargets: __expectInt32(output.NumberOfMountTargets),
|
|
4179
|
-
OwnerId: __expectString(output.OwnerId),
|
|
4180
|
-
PerformanceMode: __expectString(output.PerformanceMode),
|
|
4181
|
-
ProvisionedThroughputInMibps: __limitedParseDouble(output.ProvisionedThroughputInMibps),
|
|
4182
|
-
SizeInBytes:
|
|
4183
|
-
output.SizeInBytes !== undefined && output.SizeInBytes !== null
|
|
4184
|
-
? deserializeAws_restJson1FileSystemSize(output.SizeInBytes, context)
|
|
4185
|
-
: undefined,
|
|
4186
|
-
Tags:
|
|
4187
|
-
output.Tags !== undefined && output.Tags !== null
|
|
4188
|
-
? deserializeAws_restJson1Tags(output.Tags, context)
|
|
4189
|
-
: undefined,
|
|
4190
|
-
ThroughputMode: __expectString(output.ThroughputMode),
|
|
4191
|
-
} as any;
|
|
4192
|
-
};
|
|
4193
|
-
|
|
4194
|
-
const deserializeAws_restJson1FileSystemDescriptions = (
|
|
4195
|
-
output: any,
|
|
4196
|
-
context: __SerdeContext
|
|
4197
|
-
): FileSystemDescription[] => {
|
|
4198
|
-
return (output || [])
|
|
4199
|
-
.filter((e: any) => e != null)
|
|
4200
|
-
.map((entry: any) => {
|
|
4201
|
-
if (entry === null) {
|
|
4202
|
-
return null as any;
|
|
4203
|
-
}
|
|
4204
|
-
return deserializeAws_restJson1FileSystemDescription(entry, context);
|
|
4205
|
-
});
|
|
4206
|
-
};
|
|
4207
|
-
|
|
4208
|
-
const deserializeAws_restJson1FileSystemSize = (output: any, context: __SerdeContext): FileSystemSize => {
|
|
4209
|
-
return {
|
|
4210
|
-
Timestamp:
|
|
4211
|
-
output.Timestamp !== undefined && output.Timestamp !== null
|
|
4212
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Timestamp)))
|
|
4213
|
-
: undefined,
|
|
4214
|
-
Value: __expectLong(output.Value),
|
|
4215
|
-
ValueInIA: __expectLong(output.ValueInIA),
|
|
4216
|
-
ValueInStandard: __expectLong(output.ValueInStandard),
|
|
4217
|
-
} as any;
|
|
4218
|
-
};
|
|
4219
|
-
|
|
4220
|
-
const deserializeAws_restJson1LifecyclePolicies = (output: any, context: __SerdeContext): LifecyclePolicy[] => {
|
|
4221
|
-
return (output || [])
|
|
4222
|
-
.filter((e: any) => e != null)
|
|
4223
|
-
.map((entry: any) => {
|
|
4224
|
-
if (entry === null) {
|
|
4225
|
-
return null as any;
|
|
4226
|
-
}
|
|
4227
|
-
return deserializeAws_restJson1LifecyclePolicy(entry, context);
|
|
4228
|
-
});
|
|
4229
|
-
};
|
|
4230
|
-
|
|
4231
|
-
const deserializeAws_restJson1LifecyclePolicy = (output: any, context: __SerdeContext): LifecyclePolicy => {
|
|
4232
|
-
return {
|
|
4233
|
-
TransitionToIA: __expectString(output.TransitionToIA),
|
|
4234
|
-
TransitionToPrimaryStorageClass: __expectString(output.TransitionToPrimaryStorageClass),
|
|
4235
|
-
} as any;
|
|
4236
|
-
};
|
|
4237
|
-
|
|
4238
|
-
const deserializeAws_restJson1MountTargetDescription = (
|
|
4239
|
-
output: any,
|
|
4240
|
-
context: __SerdeContext
|
|
4241
|
-
): MountTargetDescription => {
|
|
4242
|
-
return {
|
|
4243
|
-
AvailabilityZoneId: __expectString(output.AvailabilityZoneId),
|
|
4244
|
-
AvailabilityZoneName: __expectString(output.AvailabilityZoneName),
|
|
4245
|
-
FileSystemId: __expectString(output.FileSystemId),
|
|
4246
|
-
IpAddress: __expectString(output.IpAddress),
|
|
4247
|
-
LifeCycleState: __expectString(output.LifeCycleState),
|
|
4248
|
-
MountTargetId: __expectString(output.MountTargetId),
|
|
4249
|
-
NetworkInterfaceId: __expectString(output.NetworkInterfaceId),
|
|
4250
|
-
OwnerId: __expectString(output.OwnerId),
|
|
4251
|
-
SubnetId: __expectString(output.SubnetId),
|
|
4252
|
-
VpcId: __expectString(output.VpcId),
|
|
4253
|
-
} as any;
|
|
4254
|
-
};
|
|
4255
|
-
|
|
4256
|
-
const deserializeAws_restJson1MountTargetDescriptions = (
|
|
4257
|
-
output: any,
|
|
4258
|
-
context: __SerdeContext
|
|
4259
|
-
): MountTargetDescription[] => {
|
|
4260
|
-
return (output || [])
|
|
4261
|
-
.filter((e: any) => e != null)
|
|
4262
|
-
.map((entry: any) => {
|
|
4263
|
-
if (entry === null) {
|
|
4264
|
-
return null as any;
|
|
4265
|
-
}
|
|
4266
|
-
return deserializeAws_restJson1MountTargetDescription(entry, context);
|
|
4267
|
-
});
|
|
4268
|
-
};
|
|
4269
|
-
|
|
4270
|
-
const deserializeAws_restJson1PosixUser = (output: any, context: __SerdeContext): PosixUser => {
|
|
4271
|
-
return {
|
|
4272
|
-
Gid: __expectLong(output.Gid),
|
|
4273
|
-
SecondaryGids:
|
|
4274
|
-
output.SecondaryGids !== undefined && output.SecondaryGids !== null
|
|
4275
|
-
? deserializeAws_restJson1SecondaryGids(output.SecondaryGids, context)
|
|
4276
|
-
: undefined,
|
|
4277
|
-
Uid: __expectLong(output.Uid),
|
|
4278
|
-
} as any;
|
|
4279
|
-
};
|
|
4280
|
-
|
|
4281
|
-
const deserializeAws_restJson1ResourceIdPreference = (output: any, context: __SerdeContext): ResourceIdPreference => {
|
|
4282
|
-
return {
|
|
4283
|
-
ResourceIdType: __expectString(output.ResourceIdType),
|
|
4284
|
-
Resources:
|
|
4285
|
-
output.Resources !== undefined && output.Resources !== null
|
|
4286
|
-
? deserializeAws_restJson1Resources(output.Resources, context)
|
|
4287
|
-
: undefined,
|
|
4288
|
-
} as any;
|
|
4289
|
-
};
|
|
4290
|
-
|
|
4291
|
-
const deserializeAws_restJson1Resources = (output: any, context: __SerdeContext): (Resource | string)[] => {
|
|
4292
|
-
return (output || [])
|
|
4293
|
-
.filter((e: any) => e != null)
|
|
4294
|
-
.map((entry: any) => {
|
|
4295
|
-
if (entry === null) {
|
|
4296
|
-
return null as any;
|
|
4297
|
-
}
|
|
4298
|
-
return __expectString(entry) as any;
|
|
4299
|
-
});
|
|
4300
|
-
};
|
|
4301
|
-
|
|
4302
|
-
const deserializeAws_restJson1RootDirectory = (output: any, context: __SerdeContext): RootDirectory => {
|
|
4303
|
-
return {
|
|
4304
|
-
CreationInfo:
|
|
4305
|
-
output.CreationInfo !== undefined && output.CreationInfo !== null
|
|
4306
|
-
? deserializeAws_restJson1CreationInfo(output.CreationInfo, context)
|
|
4307
|
-
: undefined,
|
|
4308
|
-
Path: __expectString(output.Path),
|
|
4309
|
-
} as any;
|
|
4310
|
-
};
|
|
4311
|
-
|
|
4312
|
-
const deserializeAws_restJson1SecondaryGids = (output: any, context: __SerdeContext): number[] => {
|
|
4313
|
-
return (output || [])
|
|
4314
|
-
.filter((e: any) => e != null)
|
|
4315
|
-
.map((entry: any) => {
|
|
4316
|
-
if (entry === null) {
|
|
4317
|
-
return null as any;
|
|
4318
|
-
}
|
|
4319
|
-
return __expectLong(entry) as any;
|
|
4320
|
-
});
|
|
4321
|
-
};
|
|
4322
|
-
|
|
4323
|
-
const deserializeAws_restJson1SecurityGroups = (output: any, context: __SerdeContext): string[] => {
|
|
4324
|
-
return (output || [])
|
|
4325
|
-
.filter((e: any) => e != null)
|
|
4326
|
-
.map((entry: any) => {
|
|
4327
|
-
if (entry === null) {
|
|
4328
|
-
return null as any;
|
|
4329
|
-
}
|
|
4330
|
-
return __expectString(entry) as any;
|
|
4331
|
-
});
|
|
4332
|
-
};
|
|
4333
|
-
|
|
4334
|
-
const deserializeAws_restJson1Tag = (output: any, context: __SerdeContext): Tag => {
|
|
4335
|
-
return {
|
|
4336
|
-
Key: __expectString(output.Key),
|
|
4337
|
-
Value: __expectString(output.Value),
|
|
4338
|
-
} as any;
|
|
4339
|
-
};
|
|
4340
|
-
|
|
4341
|
-
const deserializeAws_restJson1Tags = (output: any, context: __SerdeContext): Tag[] => {
|
|
4342
|
-
return (output || [])
|
|
4343
|
-
.filter((e: any) => e != null)
|
|
4344
|
-
.map((entry: any) => {
|
|
4345
|
-
if (entry === null) {
|
|
4346
|
-
return null as any;
|
|
4347
|
-
}
|
|
4348
|
-
return deserializeAws_restJson1Tag(entry, context);
|
|
4349
|
-
});
|
|
4350
|
-
};
|
|
4351
|
-
|
|
4352
|
-
const deserializeMetadata = (output: __HttpResponse): __ResponseMetadata => ({
|
|
4353
|
-
httpStatusCode: output.statusCode,
|
|
4354
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"],
|
|
4355
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
4356
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
4357
|
-
});
|
|
4358
|
-
|
|
4359
|
-
// Collect low-level response body stream to Uint8Array.
|
|
4360
|
-
const collectBody = (streamBody: any = new Uint8Array(), context: __SerdeContext): Promise<Uint8Array> => {
|
|
4361
|
-
if (streamBody instanceof Uint8Array) {
|
|
4362
|
-
return Promise.resolve(streamBody);
|
|
4363
|
-
}
|
|
4364
|
-
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
4365
|
-
};
|
|
4366
|
-
|
|
4367
|
-
// Encode Uint8Array data into string with utf-8.
|
|
4368
|
-
const collectBodyString = (streamBody: any, context: __SerdeContext): Promise<string> =>
|
|
4369
|
-
collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
4370
|
-
|
|
4371
|
-
const isSerializableHeaderValue = (value: any): boolean =>
|
|
4372
|
-
value !== undefined &&
|
|
4373
|
-
value !== null &&
|
|
4374
|
-
value !== "" &&
|
|
4375
|
-
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
4376
|
-
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
4377
|
-
|
|
4378
|
-
const parseBody = (streamBody: any, context: __SerdeContext): any =>
|
|
4379
|
-
collectBodyString(streamBody, context).then((encoded) => {
|
|
4380
|
-
if (encoded.length) {
|
|
4381
|
-
return JSON.parse(encoded);
|
|
4382
|
-
}
|
|
4383
|
-
return {};
|
|
4384
|
-
});
|
|
4385
|
-
|
|
4386
|
-
/**
|
|
4387
|
-
* Load an error code for the aws.rest-json-1.1 protocol.
|
|
4388
|
-
*/
|
|
4389
|
-
const loadRestJsonErrorCode = (output: __HttpResponse, data: any): string => {
|
|
4390
|
-
const findKey = (object: any, key: string) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
4391
|
-
|
|
4392
|
-
const sanitizeErrorCode = (rawValue: string): string => {
|
|
4393
|
-
let cleanValue = rawValue;
|
|
4394
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
4395
|
-
cleanValue = cleanValue.split(":")[0];
|
|
4396
|
-
}
|
|
4397
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
4398
|
-
cleanValue = cleanValue.split("#")[1];
|
|
4399
|
-
}
|
|
4400
|
-
return cleanValue;
|
|
4401
|
-
};
|
|
4402
|
-
|
|
4403
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
4404
|
-
if (headerKey !== undefined) {
|
|
4405
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
4406
|
-
}
|
|
4407
|
-
|
|
4408
|
-
if (data.code !== undefined) {
|
|
4409
|
-
return sanitizeErrorCode(data.code);
|
|
4410
|
-
}
|
|
4411
|
-
|
|
4412
|
-
if (data["__type"] !== undefined) {
|
|
4413
|
-
return sanitizeErrorCode(data["__type"]);
|
|
4414
|
-
}
|
|
4415
|
-
|
|
4416
|
-
return "";
|
|
4417
|
-
};
|