Package dnb.data.filetree

Examples of dnb.data.filetree.Component


  }

 
  public static void analyzeFolders(Repository repository, List<Folder> list, AlbumDataConfirmInteraction confirmInteraction) {
    int s;
    Component c;
    NfoLyzer nfoLyzer = new NfoLyzer();
       
    for (Folder f : list) { // for all folders,
      s = f.size();
     
      NfoLyzeResult result = new NfoLyzeResult(f); // one nfo result per folder... 
     
      for (int i = 0; i < s; i++) { // iterate files,
        c = f.get(i);
        if (c instanceof NfoFile) { // find nfos
          try {
            if (!nfoLyzer.parseNfo(result, (NfoFile) c)) {
              System.out.println("No parser for " + c.pathString() + ", trying next nfo.");             
              continue;             
            } else {
              // parse success => validate, create & save album data
              // set repository object candidates and the status of all index fields
              assignMatchStati(result, repository); // find known or similar entries & set stati accordingly
View Full Code Here


  }
 
  private static CatalogNumberHibernateImpl fromNfo(Folder f) {
   
    final int s = f.size();
    Component c;
    CatalogNumberHibernateImpl lc = null;
    String lm = null;
    for (int i = 0; i < s; i++) {
      c = f.get(i);
      if (c instanceof NfoFile) {
        String pth = c.pathString();
        try {
          System.out.println("Processing " + pth);
          String nfo = IOUtils.toString(new FileReader(pth));
          Matcher m = NFO_LABELCODE_PATTERN.matcher(nfo);
         
View Full Code Here

TOP

Related Classes of dnb.data.filetree.Component

Copyright © 2018 www.massapicom. 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.