Introduction to enums in Swift

แชร์
ฝัง
  • เผยแพร่เมื่อ 16 พ.ย. 2024

ความคิดเห็น • 29

  • @shadieossei4336
    @shadieossei4336 3 ปีที่แล้ว +2

    This is the best explanation for enums on TH-cam. I really like how you teach and how you break your lessons down topic by topic! You're awesome!

    • @StewartLynch
      @StewartLynch  3 ปีที่แล้ว +1

      Glad it was helpful!

    • @shadieossei4336
      @shadieossei4336 3 ปีที่แล้ว

      @@StewartLynch It was very helpful! Thanks a lot.

  • @macmcmillen6282
    @macmcmillen6282 ปีที่แล้ว

    Excellent as usual. Thanks Stewart.

  • @tigran.zakaryan
    @tigran.zakaryan 2 ปีที่แล้ว

    Very deep explanation of each topic. Thank You!

  • @sokolek310385
    @sokolek310385 3 ปีที่แล้ว

    For me as beginner the best video so far! Huge THANKS 🙏

  • @andrejkling3886
    @andrejkling3886 3 ปีที่แล้ว +1

    Thank you very much Stewart...

  • @rungxanh2901
    @rungxanh2901 3 ปีที่แล้ว

    I'm grateful for this Stewart. Amazing help to jog my memory on the spot 🥰

  • @ضدالظلم-د4ح
    @ضدالظلم-د4ح 4 ปีที่แล้ว

    Thank you so much ☺️
    I was looking for it 👍👍
    I had problems with understanding enum before 😳
    You are fantastic ❤️😍❤️

  • @gakkieNL
    @gakkieNL 4 ปีที่แล้ว

    Looking forward to your new videos!

    • @StewartLynch
      @StewartLynch  4 ปีที่แล้ว

      The previous ones are OK too :).

  • @radhapatel5848
    @radhapatel5848 4 ปีที่แล้ว

    Thank you for this video! It was very helpful!

  • @ArchAid1
    @ArchAid1 3 ปีที่แล้ว

    I'm pursuing perfection with Enums. However, I have run into a problem that two hours of googling and trial and error wasn't able to surmount. I have a list of options that I am iterating over in a ForEach loop (SwiftUI, obviously). I would like the user to be able to turn these options on or off. I'm using the CaseIterable to do this (.allCases). And I have a computed variable called "selected" (Bool) that is set to false by default. I would like the user to be able to tap the option to turn it on (ie. to change the state of the selected. Is there a way out of this?

    • @StewartLynch
      @StewartLynch  3 ปีที่แล้ว +1

      Can you DM me on Twitter or send me an email and we can discuss.

  • @eliasengineering753
    @eliasengineering753 4 ปีที่แล้ว

    Thank You Very Much Really Helpful!!!

  • @jankuna9479
    @jankuna9479 2 ปีที่แล้ว

    10:10 "This works for Ints, Doubles and Floats"
    I tried this:
    enum Numbers: Double {
    case one = 1.0
    case two
    .
    .
    case five
    }
    //Xcode: 'Numbers' declares raw type 'Double', but does not conform to RawRepresentable and conformance could not be synthesized.
    //Xcode: Enum case must declare a raw value when the preceding raw value is not an integer
    So, autosetting rawValues for next cases fails
    What I'm doing wrong? Merci!

    • @StewartLynch
      @StewartLynch  2 ปีที่แล้ว

      change your case to case one = 1 and not 1.0

    • @jankuna9479
      @jankuna9479 2 ปีที่แล้ว

      ​@@StewartLynch Sorry, my own mistake. It works now. Thank you.

  • @sazidhasandip6854
    @sazidhasandip6854 3 ปีที่แล้ว

    when will your new video will come ?

    • @StewartLynch
      @StewartLynch  3 ปีที่แล้ว

      I try to release a new video every Sunday. Subscribe to my channel and ring the bell and you will get notified.

  • @firemob955
    @firemob955 4 ปีที่แล้ว

    Hi can you show us how to make list to list array in swiftui! Thanks

    • @StewartLynch
      @StewartLynch  4 ปีที่แล้ว

      I am sorry but I don’t understand what you mean. Can you explain more?

    • @firemob955
      @firemob955 4 ปีที่แล้ว

      ​@@StewartLynch table view to to table view in UIKIT.
      How do you pass data from one list view to another. So far I didn't find one video explaining this. Thanks

    • @StewartLynch
      @StewartLynch  4 ปีที่แล้ว +1

      My focus is more on SwiftUI now along with core Swift language concepts. What you are looking for is a tutorial on passing data from one viewcontroller to another. You don’t pass data from a table view to another. The viewcontroller usually handles this through datasource delegation.