Package org.gudy.azureus2.core3.logging

Examples of org.gudy.azureus2.core3.logging.LogAlert


              // where we're mapping to is already linked somewhere else. Only case we support
              // is where this is a remapping of the same file back to where it came from
 
          if ( !from_file.equals( to_link )){
 
              Logger.log(new LogAlert(download_manager, LogAlert.REPEATABLE, LogAlert.AT_ERROR,
                              "Attempt to link to existing link '" + existing_link.toString()
                                      + "'"));
 
              return( false );
          }
      }
 
      File    existing_file = file_info.getFile( true );
 
      if ( to_link.equals( existing_file )){
 
              // already pointing to the right place
 
          return( true );
      }
 
      for (int i=0;i<info.length;i++){
 
          if ( to_link.equals( info[i].getFile( true ))){
 
              Logger.log(new LogAlert(download_manager, LogAlert.REPEATABLE, LogAlert.AT_ERROR,
                              "Attempt to link to existing file '" + info[i].getFile(true)
                                      + "'"));
 
              return( false );
          }
      }
 
      if ( to_link.exists()){
 
          if ( !existing_file.exists()){
 
                  // using a new file, make sure we recheck
 
              download_manager.recheckFile( file_info );
 
          }else{
 
                if ( FileUtil.deleteWithRecycle(
                existing_file,
                download_manager.getDownloadState().getFlag( DownloadManagerState.FLAG_LOW_NOISE ))){
 
                      // new file, recheck
 
                  download_manager.recheckFile( file_info );
 
              }else{
 
                  Logger.log(new LogAlert(download_manager, LogAlert.REPEATABLE, LogAlert.AT_ERROR,
                          "Failed to delete '" + existing_file.toString() + "'"));
 
                  return( false );
              }
          }
      }else{
 
          if ( existing_file.exists()){
 
              if ( !FileUtil.renameFile( existing_file, to_link )){
 
                  Logger.log(new LogAlert(download_manager, LogAlert.REPEATABLE, LogAlert.AT_ERROR,
                      "Failed to rename '" + existing_file.toString() + "'" ));
 
                  return( false );
              }
          }
View Full Code Here


              }catch( Throwable e ){
 
                Debug.printStackTrace(e);
 
                Logger.log(
                  new LogAlert(download_manager,
                    LogAlert.REPEATABLE,
                    LogAlert.AT_ERROR,
                    "Failed to change storage type for '" + res[i].getFile(true) +"': " + Debug.getNestedExceptionMessage(e)));
 
                // download's not running - tag for recheck
View Full Code Here

         
          az_exe = null;
         
          if (!az_exe_checked){
         
            Logger.log(new LogAlert(LogAlert.UNREPEATABLE, LogAlert.AT_WARNING,
                msg));
          }
         
          throw( new PlatformManagerException( msg ));
        }
View Full Code Here

          at = LogAlert.AT_ERROR;
          break;
        }
      }

      org.gudy.azureus2.core3.logging.Logger.log(new LogAlert(repeatable, at,
          message));
    }
  }
View Full Code Here

        Debug.printStackTrace( f );
      }
    } 

    if ( !no_output ){
      org.gudy.azureus2.core3.logging.Logger.log(new LogAlert(
          LogAlert.UNREPEATABLE, message, e));
    }
  } 
View Full Code Here

        Debug.printStackTrace( f );
      }
    } 
   
    if ( !no_output ){
      org.gudy.azureus2.core3.logging.Logger.log(new LogAlert(
          LogAlert.REPEATABLE, message, e));
    }
  }
View Full Code Here

       
      if ( bundle_fail_count == 1 ){
       
        e.printStackTrace();
       
        Logger.log(new LogAlert(LogAlert.REPEATABLE, LogAlert.AT_ERROR,
            "Failed to load resource bundle. One possible cause is "
                + "that you have installed " + Constants.APP_NAME + " into a directory "
                + "with a '!' in it. If so, please remove the '!'."));
      }
     
View Full Code Here

  public void addListener(ILogAlertListener l) {
    alertListeners.add(l);

    for (int i = 0; i < alertHistory.size(); i++) {
      LogAlert alert = (LogAlert) alertHistory.get(i);
      l.alertRaised(alert);
    }
  }
View Full Code Here

                    if ( failed_accepts > 100 && successfull_accepts == 0 ){

                        // looks like its not going to work...
                        // some kind of socket problem
                             
                      Logger.logTextResource(new LogAlert(LogAlert.UNREPEATABLE,
                        LogAlert.AT_ERROR, "Network.alert.acceptfail"),
                        new String[] { "" + filter_port, "TCP" });
                 
                      use_filter  = false;
                     
                      break;
                    }
                  }
                }
              }
            };
     
        accept_thread.setDaemon( true );
     
        accept_thread.start();                 
     
        if (Logger.isEnabled())
          Logger.log(new LogEvent(LOGID,
              "ClientIDManager: listener established on port " + filter_port));
       
      }catch( Throwable e){
     
        Logger.logTextResource(new LogAlert(LogAlert.UNREPEATABLE,
            LogAlert.AT_ERROR, "Tracker.alert.listenfail"), new String[] { ""
            + filter_port });
   
        if (Logger.isEnabled())
          Logger.log(new LogEvent(LOGID,
View Full Code Here

     
      URL  url = (URL)properties.get( ClientIDGenerator.PR_URL );
     
      if ( !url.getProtocol().toLowerCase().equals( "http" )){
       
        Logger.log(new LogAlert(LogAlert.UNREPEATABLE, LogAlert.AT_ERROR,
            "ClientIDManager only supports filtering of http, not https"));
       
        return;
      }
     
View Full Code Here

TOP

Related Classes of org.gudy.azureus2.core3.logging.LogAlert

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.