/*
 * Copyright 2000-2017 JetBrains s.r.o.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.intellij.debugger.streams.lib.impl

import com.intellij.debugger.streams.lib.LibrarySupport
import com.intellij.openapi.components.ProjectComponent
import com.intellij.openapi.project.Project

/**
 * @author Vitaliy.Bibaev
 */
class LibraryManager(project: Project) : ProjectComponent {
  private val myLibraries: List<LibrarySupport>

  init {
    val std = StandardLibrarySupport(project)
    val streamEx = StreamExLibrarySupport(project)
    myLibraries = listOf(std, streamEx)
  }

  fun getLibraryByPackage(packageName: String): LibrarySupport? = myLibraries.find { it.description.packageName == packageName }
}

Add project component to manage supported libraries/languages
Add project component to manage supported libraries/languages

mglukhikh/intellij-community,da1z/intellij-community,xfournet/intellij-community,xfournet/intellij-community,allotria/intellij-community,allotria/intellij-community,ThiagoGarciaAlves/intellij-community,ThiagoGarciaAlves/intellij-community,allotria/intellij-community,xfournet/intellij-community,mglukhikh/intellij-community,da1z/intellij-community,ThiagoGarciaAlves/intellij-community,mglukhikh/intellij-community,mglukhikh/intellij-community,da1z/intellij-community,da1z/intellij-community,xfournet/intellij-community,allotria/intellij-community,ThiagoGarciaAlves/intellij-community,da1z/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,xfournet/intellij-community,da1z/intellij-community,da1z/intellij-community,xfournet/intellij-community,xfournet/intellij-community,xfournet/intellij-community,allotria/intellij-community,da1z/intellij-community,mglukhikh/intellij-community,ThiagoGarciaAlves/intellij-community,mglukhikh/intellij-community,mglukhikh/intellij-community,xfournet/intellij-community,ThiagoGarciaAlves/intellij-community,ThiagoGarciaAlves/intellij-community,xfournet/intellij-community,da1z/intellij-community,mglukhikh/intellij-community,mglukhikh/intellij-community,ThiagoGarciaAlves/intellij-community,allotria/intellij-community,xfournet/intellij-community,xfournet/intellij-community,allotria/intellij-community,da1z/intellij-community,mglukhikh/intellij-community,mglukhikh/intellij-community,allotria/intellij-community,ThiagoGarciaAlves/intellij-community,mglukhikh/intellij-community,ThiagoGarciaAlves/intellij-community,xfournet/intellij-community,ThiagoGarciaAlves/intellij-community,ThiagoGarciaAlves/intellij-community,da1z/intellij-community,allotria/intellij-community,mglukhikh/intellij-community,allotria/intellij-community,da1z/intellij-community,da1z/intellij-community