public Collection<ViewInstanceEntity> getInstanceDefinitions(ViewEntity definition) {
    if (definition != null) {
      Map<String, ViewInstanceEntity> instanceEntityMap = viewInstanceDefinitions.get(definition);
      if (instanceEntityMap != null) {
        return instanceEntityMap.values();
      }
    }
    return Collections.emptyList();
  }
Get the collection of view instances for the given view definition.

@param definition the view definition
@return the collection of view instances for the view definition
ambari-server/src/main/java/org/apache/ambari/server/view/ViewRegistry.java