Member Access Operator In Dart

Published on 29 March 2020
Last Updated on 29 March 2020

Member access operator is used for accessing member of an instance of a class or property of an expression.

Refer to following program to know when and how member access operator is used.

Program using member access operator

class Person {
  // name is a member of class Person
  String name;

main(List<String> args) {
  // initializing variable p
  var p = Person();
  // defining using member access operator = 'hello';

  // using the member access operator to get the updated value of p
  var name =;

Above program produces following output: