getOrCreateScope static method

Scope getOrCreateScope(
  1. List<Module> modules,
  2. String scopeId,
  3. String scopeName
)

Implementation

static Scope getOrCreateScope(final List<Module> modules, final String scopeId, final String scopeName) {
  final scope = _resolveScope(scopeId);
  if (scope != null) {
    return getScope(scopeId);
  } else {
    return createScope(modules, scopeId, scopeName);
  }
}