What is de-initializer and how it is written in Swift?
Answer / iosraj
A de-initializer is declared immediately before a class instance is de-allocated. You write de-initializer with the deinit keyword. De-initializer is written without any parenthesis, and it does not take any parameters. It is written as
deinit {
// perform the deinitialization
}
| Is This Answer Correct ? | 0 Yes | 0 No |
What is interface in swift?
What do you mean by optional chaining in swift?
Do swift classes inherit from nsobject?
How can you declare a variable in swift?
What is observer in swift?
Explain any three-shift pattern matching techniques?
Why is swift important?
What are the different ways to pass data in swift?
Explain how multiple line comment can be written in swift?
What is the meaning of question mark "?" In swift?
Does swift have abstract classes?
What type of objects are basic data types in swift?