#33 Kotlin Tutorial | Data Class

Поділитися
Вставка
  • Опубліковано 1 гру 2024

КОМЕНТАРІ • 19

  • @hammadpervez4568
    @hammadpervez4568 5 років тому +2

    Lots of love for your efforts from Pakistan :)

  • @whatnot798
    @whatnot798 5 років тому +1

    Awesome work as usual....Just began to learn how to code. How come sometimes you give the variable, default values like zero for age but you dont do it here. (For instance the example on constructors)

  • @learnwithmanu5655
    @learnwithmanu5655 7 років тому

    sir thanx alot .please upload videos as soon as possible .please sir .excellent way of explaining the concept.

  • @ruchajoshi5671
    @ruchajoshi5671 3 роки тому

    Explained very well! Thank you for this Video x

  • @arsalanchishti5105
    @arsalanchishti5105 7 років тому

    really this is efficient . and Very good explanation

  • @bijesh1984
    @bijesh1984 6 років тому

    Data class seems to be nice feature however its adds a security flaw. for instance if we do a print on the log file the objects enitre atrributes with its value will be shown on the log. Say I am having a User Data object and if I print the log it will print user name and password on the log

  • @dhanarajs2707
    @dhanarajs2707 6 років тому

    mahn u r awesome...keep the work on...

  • @rahulrawat329
    @rahulrawat329 5 років тому +1

    Can you please show me the reference where i can achieve the same using toString(), equals(), hascode() and clone() methods

  • @jaserq
    @jaserq 4 роки тому

    you are perfect as allways. ! Could you please consider about inheritence in data classes.I know data classes cannot inherit.. but can you show us way to do that in kotlin for POJO ?

  • @r4k4210
    @r4k4210 5 років тому

    Nice explanation. Thanks

  • @anirbansaha8510
    @anirbansaha8510 6 років тому +1

    i have one question, you are using val in primary constructor section but you change price value in .copy() function how it is possible?

    • @Voxxorian
      @Voxxorian 4 роки тому +2

      I know this comment is at least a year old, but answering anyway:
      The val in the constructor simply means that the values in a laptop cannot be changed once it's constructed.
      Copy creates an entirely new object, using the variables that were used to construct the original. The copy() with the price value simply reads the variables of lap1 when constructing the new object, but ignores lap1's price value, and instead uses the one given to the copy method.

  • @siddharthsinghh
    @siddharthsinghh 3 роки тому

    Can we use data and open keyword at same time

  • @satyam2177
    @satyam2177 7 років тому

    awesome work sir

  • @satyam2177
    @satyam2177 7 років тому

    Keep doing that..

  • @sanjogpanda2597
    @sanjogpanda2597 4 роки тому

    Never seen a more confused man

  • @tranphu8348
    @tranphu8348 7 років тому

    Tks you!

  • @vikkyvikky7545
    @vikkyvikky7545 3 роки тому

    aliens hahaha

  • @danielhadar3098
    @danielhadar3098 4 роки тому

    Apple is clearly not happy with you teaching Kotlin, enable siri!