Last active
November 9, 2020 21:15
-
-
Save yenerm/7dfad2f905a74c854d627dd2f2e22f71 to your computer and use it in GitHub Desktop.
lazy() sample
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Copyright 2020 Google LLC. | |
SPDX-License-Identifier: Apache-2.0 --> | |
class Person(name: String, lastname: String) { | |
val fullname: String by lazy() { | |
name + lastname | |
} | |
//... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment