Dart – Super keyword

In Dart, super keyword is used to refer immediate parent class object. It is used to call properties and methods of the superclass. It does not call the method, whereas when we create an instance of subclass than that of the parent class is created implicitly so super keyword calls that instance. Advantages of super keyword: It… Continue reading Dart – Super keyword

Dart – Loop Control Statements (Break and Continue)

Dart supports two types of loop control statements: Break Statement Continue Statement Break Statement: This statement is used to break the flow of control of the loop i.e if it is used within a loop then it will terminate the loop whenever encountered. It will bring the flow of control out of the nearest loop.… Continue reading Dart – Loop Control Statements (Break and Continue)

How to Replace a Substring of a String in Dart?

To replace all the substring of a string we make use of  replaceAll method in Dart. This method replaces all the substring in the given string to the desired substring. Returns a new string in which the non-overlapping substrings matching from (the ones iterated by from.allMatches(this String)) are replaced by the literal string replace. Syntax:… Continue reading How to Replace a Substring of a String in Dart?

Dart – Getters and Setters

Getters and Setters, also called accessors and mutators, allow the program to initialize and retrieve the values of class fields respectively.  Getters or accessors are defined using the get keyword. Setters or mutators are defined using the set keyword. A default getter/setter is associated with every class. However, the default ones can be overridden by explicitly defining a setter/ getter.… Continue reading Dart – Getters and Setters

Flutter-Asset Image

In Flutter, you can use asset images to include images in your app. Asset images are typically used for icons, images, and other static resources that your app needs. Steps to Add an Image: 1)Create a new folder in the root of your flutter project. You can name it whatever you want, but assets are preferred. Inside this… Continue reading Flutter-Asset Image

Published
Categorized as Mobile App