Skip to content

Commit e75e5a2

Browse files
authored
[swift] remove unavailable property to fix Xcode 15 compiler error (#16504)
1 parent ec59334 commit e75e5a2

17 files changed

Lines changed: 0 additions & 153 deletions

File tree

modules/openapi-generator/src/main/resources/swift5/libraries/urlsession/URLSessionImplementations.mustache

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ private var credentialStore = SynchronizedDictionary<Int, URLCredential>()
4646
*/
4747
{{#nonPublicApi}}internal{{/nonPublicApi}}{{^nonPublicApi}}public{{/nonPublicApi}} var taskDidReceiveChallenge: {{projectName}}APIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
{{#nonPublicApi}}internal{{/nonPublicApi}}{{^nonPublicApi}}public{{/nonPublicApi}} var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required {{#nonPublicApi}}internal{{/nonPublicApi}}{{^nonPublicApi}}public{{/nonPublicApi}} init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/anycodableLibrary/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/asyncAwaitLibrary/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/combineLibrary/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/default/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/deprecated/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/frozenEnums/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/nonPublicApi/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ internal class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
internal var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
internal var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required internal init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/objcCompatible/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

samples/client/petstore/swift5/oneOf/PetstoreClient/Classes/OpenAPIs/URLSessionImplementations.swift

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,6 @@ open class URLSessionRequestBuilder<T>: RequestBuilder<T> {
4646
*/
4747
public var taskDidReceiveChallenge: PetstoreClientAPIChallengeHandler?
4848

49-
/**
50-
May be assigned if you want to do any of those things:
51-
- control the task completion
52-
- intercept and handle errors like authorization
53-
- retry the request.
54-
*/
55-
@available(*, unavailable, message: "Please override execute() method to intercept and handle errors like authorization or retry the request. Check the Wiki for more info. https://github.com/OpenAPITools/openapi-generator/wiki/FAQ#how-do-i-implement-bearer-token-authentication-with-urlsession-on-the-swift-api-client")
56-
public var taskCompletionShouldRetry: ((Data?, URLResponse?, Error?, @escaping (Bool) -> Void) -> Void)?
57-
5849
required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) {
5950
super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication)
6051
}

0 commit comments

Comments
 (0)