property in Vala
This commit is contained in:
parent
aaf7ad9144
commit
b83c99e889
9
vala/property/property.vala
Normal file
9
vala/property/property.vala
Normal file
@ -0,0 +1,9 @@
|
||||
public class Person : Object {
|
||||
public string height { get; set; default = null; }
|
||||
}
|
||||
|
||||
void main () {
|
||||
var p = new Person ();
|
||||
p.height = "Hello, World!";
|
||||
print (p.height);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user