Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AWSConnect Update models to latest #5005

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
226 changes: 198 additions & 28 deletions AWSConnect/AWSConnectModel.h

Large diffs are not rendered by default.

232 changes: 232 additions & 0 deletions AWSConnect/AWSConnectModel.m
Original file line number Diff line number Diff line change
Expand Up @@ -464,6 +464,21 @@ + (NSDictionary *)JSONKeyPathsByPropertyKey {

@end

@implementation AWSConnectApplication

+ (BOOL)supportsSecureCoding {
return YES;
}

+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"applicationPermissions" : @"ApplicationPermissions",
@"namespace" : @"Namespace",
};
}

@end

@implementation AWSConnectAssignContactCategoryActionDefinition

+ (BOOL)supportsSecureCoding {
Expand Down Expand Up @@ -4448,6 +4463,9 @@ + (NSValueTransformer *)integrationTypeJSONTransformer {
if ([value caseInsensitiveCompare:@"CASES_DOMAIN"] == NSOrderedSame) {
return @(AWSConnectIntegrationTypeCasesDomain);
}
if ([value caseInsensitiveCompare:@"APPLICATION"] == NSOrderedSame) {
return @(AWSConnectIntegrationTypeApplication);
}
return @(AWSConnectIntegrationTypeUnknown);
} reverseBlock:^NSString *(NSNumber *value) {
switch ([value integerValue]) {
Expand All @@ -4463,6 +4481,8 @@ + (NSValueTransformer *)integrationTypeJSONTransformer {
return @"WISDOM_KNOWLEDGE_BASE";
case AWSConnectIntegrationTypeCasesDomain:
return @"CASES_DOMAIN";
case AWSConnectIntegrationTypeApplication:
return @"APPLICATION";
default:
return nil;
}
Expand Down Expand Up @@ -4795,6 +4815,7 @@ + (BOOL)supportsSecureCoding {
+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"allowedAccessControlTags" : @"AllowedAccessControlTags",
@"applications" : @"Applications",
@"detail" : @"Description",
@"instanceId" : @"InstanceId",
@"permissions" : @"Permissions",
Expand All @@ -4804,6 +4825,10 @@ + (NSDictionary *)JSONKeyPathsByPropertyKey {
};
}

+ (NSValueTransformer *)applicationsJSONTransformer {
return [NSValueTransformer awsmtl_JSONArrayTransformerWithModelClass:[AWSConnectApplication class]];
}

@end

@implementation AWSConnectCreateSecurityProfileResponse
Expand Down Expand Up @@ -8627,6 +8652,7 @@ + (NSDictionary *)JSONKeyPathsByPropertyKey {
@"endTime" : @"EndTime",
@"filters" : @"Filters",
@"groupings" : @"Groupings",
@"interval" : @"Interval",
@"maxResults" : @"MaxResults",
@"metrics" : @"Metrics",
@"nextToken" : @"NextToken",
Expand All @@ -8647,6 +8673,10 @@ + (NSValueTransformer *)filtersJSONTransformer {
return [NSValueTransformer awsmtl_JSONArrayTransformerWithModelClass:[AWSConnectFilterV2 class]];
}

+ (NSValueTransformer *)intervalJSONTransformer {
return [NSValueTransformer awsmtl_JSONDictionaryTransformerWithModelClass:[AWSConnectIntervalDetails class]];
}

+ (NSValueTransformer *)metricsJSONTransformer {
return [NSValueTransformer awsmtl_JSONArrayTransformerWithModelClass:[AWSConnectMetricV2 class]];
}
Expand Down Expand Up @@ -9828,6 +9858,9 @@ + (NSValueTransformer *)integrationTypeJSONTransformer {
if ([value caseInsensitiveCompare:@"CASES_DOMAIN"] == NSOrderedSame) {
return @(AWSConnectIntegrationTypeCasesDomain);
}
if ([value caseInsensitiveCompare:@"APPLICATION"] == NSOrderedSame) {
return @(AWSConnectIntegrationTypeApplication);
}
return @(AWSConnectIntegrationTypeUnknown);
} reverseBlock:^NSString *(NSNumber *value) {
switch ([value integerValue]) {
Expand All @@ -9843,6 +9876,8 @@ + (NSValueTransformer *)integrationTypeJSONTransformer {
return @"WISDOM_KNOWLEDGE_BASE";
case AWSConnectIntegrationTypeCasesDomain:
return @"CASES_DOMAIN";
case AWSConnectIntegrationTypeApplication:
return @"APPLICATION";
default:
return nil;
}
Expand Down Expand Up @@ -9872,6 +9907,62 @@ + (NSValueTransformer *)sourceTypeJSONTransformer {

@end

@implementation AWSConnectIntervalDetails

+ (BOOL)supportsSecureCoding {
return YES;
}

+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"intervalPeriod" : @"IntervalPeriod",
@"timeZone" : @"TimeZone",
};
}

+ (NSValueTransformer *)intervalPeriodJSONTransformer {
return [AWSMTLValueTransformer reversibleTransformerWithForwardBlock:^NSNumber *(NSString *value) {
if ([value caseInsensitiveCompare:@"FIFTEEN_MIN"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodFifteenMin);
}
if ([value caseInsensitiveCompare:@"THIRTY_MIN"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodThirtyMin);
}
if ([value caseInsensitiveCompare:@"HOUR"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodHour);
}
if ([value caseInsensitiveCompare:@"DAY"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodDay);
}
if ([value caseInsensitiveCompare:@"WEEK"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodWeek);
}
if ([value caseInsensitiveCompare:@"TOTAL"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodTotal);
}
return @(AWSConnectIntervalPeriodUnknown);
} reverseBlock:^NSString *(NSNumber *value) {
switch ([value integerValue]) {
case AWSConnectIntervalPeriodFifteenMin:
return @"FIFTEEN_MIN";
case AWSConnectIntervalPeriodThirtyMin:
return @"THIRTY_MIN";
case AWSConnectIntervalPeriodHour:
return @"HOUR";
case AWSConnectIntervalPeriodDay:
return @"DAY";
case AWSConnectIntervalPeriodWeek:
return @"WEEK";
case AWSConnectIntervalPeriodTotal:
return @"TOTAL";
default:
return nil;
}
}];
}

@end

@implementation AWSConnectInvisibleFieldInfo

+ (BOOL)supportsSecureCoding {
Expand Down Expand Up @@ -10747,6 +10838,9 @@ + (NSValueTransformer *)integrationTypeJSONTransformer {
if ([value caseInsensitiveCompare:@"CASES_DOMAIN"] == NSOrderedSame) {
return @(AWSConnectIntegrationTypeCasesDomain);
}
if ([value caseInsensitiveCompare:@"APPLICATION"] == NSOrderedSame) {
return @(AWSConnectIntegrationTypeApplication);
}
return @(AWSConnectIntegrationTypeUnknown);
} reverseBlock:^NSString *(NSNumber *value) {
switch ([value integerValue]) {
Expand All @@ -10762,6 +10856,8 @@ + (NSValueTransformer *)integrationTypeJSONTransformer {
return @"WISDOM_KNOWLEDGE_BASE";
case AWSConnectIntegrationTypeCasesDomain:
return @"CASES_DOMAIN";
case AWSConnectIntegrationTypeApplication:
return @"APPLICATION";
default:
return nil;
}
Expand Down Expand Up @@ -12544,6 +12640,42 @@ + (NSValueTransformer *)securityKeysJSONTransformer {

@end

@implementation AWSConnectListSecurityProfileApplicationsRequest

+ (BOOL)supportsSecureCoding {
return YES;
}

+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"instanceId" : @"InstanceId",
@"maxResults" : @"MaxResults",
@"nextToken" : @"NextToken",
@"securityProfileId" : @"SecurityProfileId",
};
}

@end

@implementation AWSConnectListSecurityProfileApplicationsResponse

+ (BOOL)supportsSecureCoding {
return YES;
}

+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"applications" : @"Applications",
@"nextToken" : @"NextToken",
};
}

+ (NSValueTransformer *)applicationsJSONTransformer {
return [NSValueTransformer awsmtl_JSONArrayTransformerWithModelClass:[AWSConnectApplication class]];
}

@end

@implementation AWSConnectListSecurityProfilePermissionsRequest

+ (BOOL)supportsSecureCoding {
Expand Down Expand Up @@ -13041,11 +13173,85 @@ + (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"metricFilterKey" : @"MetricFilterKey",
@"metricFilterValues" : @"MetricFilterValues",
@"negate" : @"Negate",
};
}

@end

@implementation AWSConnectMetricInterval

+ (BOOL)supportsSecureCoding {
return YES;
}

+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"endTime" : @"EndTime",
@"interval" : @"Interval",
@"startTime" : @"StartTime",
};
}

+ (NSValueTransformer *)endTimeJSONTransformer {
return [AWSMTLValueTransformer reversibleTransformerWithForwardBlock:^id(NSNumber *number) {
return [NSDate dateWithTimeIntervalSince1970:[number doubleValue]];
} reverseBlock:^id(NSDate *date) {
return [NSString stringWithFormat:@"%f", [date timeIntervalSince1970]];
}];
}

+ (NSValueTransformer *)intervalJSONTransformer {
return [AWSMTLValueTransformer reversibleTransformerWithForwardBlock:^NSNumber *(NSString *value) {
if ([value caseInsensitiveCompare:@"FIFTEEN_MIN"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodFifteenMin);
}
if ([value caseInsensitiveCompare:@"THIRTY_MIN"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodThirtyMin);
}
if ([value caseInsensitiveCompare:@"HOUR"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodHour);
}
if ([value caseInsensitiveCompare:@"DAY"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodDay);
}
if ([value caseInsensitiveCompare:@"WEEK"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodWeek);
}
if ([value caseInsensitiveCompare:@"TOTAL"] == NSOrderedSame) {
return @(AWSConnectIntervalPeriodTotal);
}
return @(AWSConnectIntervalPeriodUnknown);
} reverseBlock:^NSString *(NSNumber *value) {
switch ([value integerValue]) {
case AWSConnectIntervalPeriodFifteenMin:
return @"FIFTEEN_MIN";
case AWSConnectIntervalPeriodThirtyMin:
return @"THIRTY_MIN";
case AWSConnectIntervalPeriodHour:
return @"HOUR";
case AWSConnectIntervalPeriodDay:
return @"DAY";
case AWSConnectIntervalPeriodWeek:
return @"WEEK";
case AWSConnectIntervalPeriodTotal:
return @"TOTAL";
default:
return nil;
}
}];
}

+ (NSValueTransformer *)startTimeJSONTransformer {
return [AWSMTLValueTransformer reversibleTransformerWithForwardBlock:^id(NSNumber *number) {
return [NSDate dateWithTimeIntervalSince1970:[number doubleValue]];
} reverseBlock:^id(NSDate *date) {
return [NSString stringWithFormat:@"%f", [date timeIntervalSince1970]];
}];
}

@end

@implementation AWSConnectMetricResultV2

+ (BOOL)supportsSecureCoding {
Expand All @@ -13056,13 +13262,18 @@ + (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"collections" : @"Collections",
@"dimensions" : @"Dimensions",
@"metricInterval" : @"MetricInterval",
};
}

+ (NSValueTransformer *)collectionsJSONTransformer {
return [NSValueTransformer awsmtl_JSONArrayTransformerWithModelClass:[AWSConnectMetricDataV2 class]];
}

+ (NSValueTransformer *)metricIntervalJSONTransformer {
return [NSValueTransformer awsmtl_JSONDictionaryTransformerWithModelClass:[AWSConnectMetricInterval class]];
}

@end

@implementation AWSConnectMetricV2
Expand Down Expand Up @@ -19863,6 +20074,22 @@ + (BOOL)supportsSecureCoding {

@end

@implementation AWSConnectUpdatePhoneNumberMetadataRequest

+ (BOOL)supportsSecureCoding {
return YES;
}

+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"clientToken" : @"ClientToken",
@"phoneNumberDescription" : @"PhoneNumberDescription",
@"phoneNumberId" : @"PhoneNumberId",
};
}

@end

@implementation AWSConnectUpdatePhoneNumberRequest

+ (BOOL)supportsSecureCoding {
Expand Down Expand Up @@ -20233,6 +20460,7 @@ + (BOOL)supportsSecureCoding {
+ (NSDictionary *)JSONKeyPathsByPropertyKey {
return @{
@"allowedAccessControlTags" : @"AllowedAccessControlTags",
@"applications" : @"Applications",
@"detail" : @"Description",
@"instanceId" : @"InstanceId",
@"permissions" : @"Permissions",
Expand All @@ -20241,6 +20469,10 @@ + (NSDictionary *)JSONKeyPathsByPropertyKey {
};
}

+ (NSValueTransformer *)applicationsJSONTransformer {
return [NSValueTransformer awsmtl_JSONArrayTransformerWithModelClass:[AWSConnectApplication class]];
}

@end

@implementation AWSConnectUpdateTaskTemplateRequest
Expand Down
Loading
Loading