# Immutable Instances

{% embed url="<https://youtu.be/j43XzqQ0Vlg>" %}

```dart
void main() {
  //immutable instances

  final employee1 =
      new Employee(id: 1, name: "John Doe", position: "CTO", companyname: "A");

  // print(employee1.toString());

//    employee1.id =2 ;

//    employee1.name = "Jane Doe";

  print(employee1.toString());
}

class Employee {
  final int id;

  final String name;

  final String position;

  final String companyname;

  @override
  String toString() {
    return "id: $id , name: $name ,  position : $position , companyname: $companyname";
  }

  Employee({this.id, this.name, this.position, this.companyname});
}


```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://eece.gitbook.io/mist-innovation-club-flutter-course-1/dart-fundamentals-1/miscellaneous-concepts/immutable-operators.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
