getInstance static method

Amplitude getInstance({
  1. String instanceName = '\$default_instance',
})

Implementation

static Amplitude getInstance({String instanceName = '\$default_instance'}) {
  if (_instances == null) {
    _instances = <String, Amplitude>{};
  }

  return _instances!
      .putIfAbsent(instanceName, () => new Amplitude(instanceName));
}