Examples of Library


Examples of com.github.fge.jsonschema.library.Library

    ValidationConfigurationBuilder()
    {
        libraries = Maps.newHashMap();
        JsonRef ref;
        Library library;
        for (final Map.Entry<SchemaVersion, Library> entry:
            DEFAULT_LIBRARIES.entrySet()) {
            ref = JsonRef.fromURI(entry.getKey().getLocation());
            library = entry.getValue();
            libraries.put(ref, library);
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

    public static Library findLibrary(final Project pProject, final Artifact pDependency) {
        final LibraryTablesRegistrar libTableMgr = LibraryTablesRegistrar.getInstance();
        final LibraryTable libTable = libTableMgr.getLibraryTable(pProject);

        String libName = pDependency.toString();
        Library lib = libTable.getLibraryByName(libName);
        if (lib == null) {
            String type = pDependency.getType();
            if (type == null || type.trim().length() == 0)
                type = "jar";
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

        final Set<VirtualFile> files = new HashSet<VirtualFile>();
        final OrderEntry[] entries = model.getOrderEntries();
        for (OrderEntry entry : entries) {
            if (entry instanceof LibraryOrderEntry) {
                final LibraryOrderEntry libEntry = (LibraryOrderEntry) entry;
                final Library lib = libEntry.getLibrary();
                if (lib == null)
                    Collections.addAll(files, libEntry.getFiles(OrderRootType.CLASSES));
                else
                    Collections.addAll(files, lib.getFiles(OrderRootType.CLASSES));
            }
            else if (pIncludeJdk || !(entry instanceof JdkOrderEntry))
                Collections.addAll(files, entry.getFiles(OrderRootType.CLASSES));
        }
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

            //
            //if a library with the name of the dependency already exists,
            //use it. Otherwise, create a new one
            //
            final Artifact artifact = problem.getArtifact();
            Library lib = IDEUtils.findLibrary(project, artifact);
            if (lib == null)
                lib = libTable.createLibrary(artifact.toString());

            //
            //get the library's modifiable model
            //
            final Library.ModifiableModel model = lib.getModifiableModel();

            //
            //calculate the dependency's location in the local repository
            //
            final PomRepoManager repoMgr = PomRepoManager.getInstance(project);
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

            final OrderEntry[] entries = model.getOrderEntries();
            for (OrderEntry entry : entries) {
                if (entry instanceof LibraryOrderEntry) {
                    final LibraryOrderEntry libEntry = (LibraryOrderEntry) entry;
                    final Library lib = libEntry.getLibrary();

                    final VirtualFile[] files;
                    if (lib == null)
                        files = libEntry.getFiles(OrderRootType.CLASSES);
                    else
                        files = lib.getFiles(OrderRootType.CLASSES);

                    for (VirtualFile file : files)
                        if (file.equals(problem.getFile()))
                            model.removeOrderEntry(libEntry);
                }
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

        for (Module module : findModulesWithLibrary(modules, libraryName)) {

          ModifiableRootModel moduleRootManager = ModuleRootManager.getInstance(module).getModifiableModel();
          LibraryTable libraryTable = moduleRootManager.getModuleLibraryTable();

          Library library = libraryTable.getLibraryByName(libraryName);
          if (library != null) libraryTable.removeLibrary(library);
          moduleRootManager.commit();

        }
      }
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

        for (Module module : findModulesWithoutLibrary(modules, libraryName)) {

          ModifiableRootModel moduleRootManager = ModuleRootManager.getInstance(module).getModifiableModel();
          LibraryTable libraryTable = moduleRootManager.getModuleLibraryTable();

          Library library = libraryTable.createLibrary(libraryName);
          Library.ModifiableModel modifiableLibrary = library.getModifiableModel();
          for (Pair<String, OrderRootType> pathAndType : paths) {
            modifiableLibrary.addRoot(pathAndType.first, pathAndType.second);
          }
          modifiableLibrary.commit();
View Full Code Here

Examples of com.intellij.openapi.roots.libraries.Library

    });
  }

  private static boolean dependsOn(String libraryName, Module module) {
    ModifiableRootModel moduleRootManager = ModuleRootManager.getInstance(module).getModifiableModel();
    Library library = moduleRootManager.getModuleLibraryTable().getLibraryByName(libraryName);
    return library != null;
  }
View Full Code Here

Examples of com.kenai.jffi.Library

        ThreadContext context = runtime.getCurrentContext();

        // Ensure the native code is initialized before we load the library
        Native n = Native.getInstance(runtime);

        Library lib = Library.openLibrary(name, Library.LAZY | Library.GLOBAL);
        if (lib == null) {
            throw new UnsatisfiedLinkError(Library.getLastError());
        }

        String fileName = new File(name).getName();
        String initName = fileName;
        int dotPos;
        if ((dotPos = fileName.lastIndexOf('.')) != -1) {
            // Remove the extension, if needed
            initName = fileName.substring(0, dotPos);
        }
        long init = lib.getSymbolAddress("Init_" + initName);
       
        if (init == 0) {
            throw new UnsatisfiedLinkError("Could not locate Init_" + initName + " module entry point");
        }
       
View Full Code Here

Examples of com.rimfaxe.webserver.compiler.Library

   * Compile the java file.
   */
  public void generateNative()
    throws NativeCompilationException, NativeLinkException
 
    Library libjsp = new Library();
    libjsp.setOutputFile( jspclass.getNativeFileName() );
    libjsp.setOutputDir(ctxt.getRoot()+"/WEB-INF/rws/jsplib");
   
    libjsp.setSource(libjsp.JAVA_SOURCE);
   
    Vector vec = new Vector();
    vec.addElement(javaFileName);
    libjsp.setInputFiles(vec);
   
    libjsp.addCompileOption("-I"+ctxt.getRoot()+"/WEB-INF/rws/src");
     
    // check for libservlets.so
    //java.io.File f1 = new java.io.File(ctxt.getRoot()+"/WEB-INF/rws/lib/libservlets.so");
    //if (f1.exists())
    //{
    //  System.out.println("JspC, libservlets.so exists");
    //  libjsp.addLinkOption("-L"+ctxt.getRoot()+"/WEB-INF/rws/lib");
    //  libjsp.addLinkOption("-lservlets");
    //}
   
    libjsp.compile();
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.