Package com.aelitis.azureus.core.networkmanager.admin

Examples of com.aelitis.azureus.core.networkmanager.admin.NetworkAdminASN


      if ( upnp_str != null ){
     
        urlStr += "&upnp=" + URLEncoder.encode( upnp_str, "UTF8" );
      }
     
      NetworkAdminASN net_asn = NetworkAdmin.getSingleton().getCurrentASN();
     
      String  as   = net_asn.getAS();
      String  asn = net_asn.getASName();
     
      if ( as.length() > 0 ){
     
          urlStr += "&as=" + URLEncoder.encode( as, "UTF8" );
          urlStr += "&asn=" + URLEncoder.encode( asn, "UTF8" );
View Full Code Here


          result.add( new trackerTarget( torrent_hash, REG_TYPE_FULL, "" ));
        }
       
        if ( ADD_ASN_DERIVED_TARGET ){
         
            NetworkAdminASN net_asn = NetworkAdmin.getSingleton().getCurrentASN();
             
            String  as   = net_asn.getAS();
            String  asn = net_asn.getASName();
 
          if ( as.length() > 0 && asn.length() > 0 ){
            
            String  key = "azderived:asn:" + as;
           
View Full Code Here

    try{
      byte[] address = (byte[])reply.get( "source_ip_address" );

      InetAddress my_ip = InetAddress.getByName( new String( address ));

      NetworkAdminASN old_asn = admin.getCurrentASN();

      NetworkAdminASN new_asn = admin.lookupCurrentASN( my_ip );

      if ( !new_asn.sameAs( old_asn )){

        // kick off a secondary version check to communicate the new information

        if ( !secondary_check_done ){

          secondary_check_done  = true;

          new AEThread( "Secondary version check", true )
          {
            public void
            runSupport()
            {
              getVersionCheckInfoSupport( REASON_SECONDARY_CHECK, false, true, v6 );
            }
          }.start();
        }
      }
    }catch( Throwable e ){

      Debug.printStackTrace(e);
    }

    Long  as_advice = (Long)reply.get( "as_advice" );

    if ( as_advice != null ){

      NetworkAdminASN current_asn = admin.getCurrentASN();

      String  asn = current_asn.getASName();

      if ( asn != null ){

        long  advice = as_advice.longValue();
View Full Code Here

        message.put( "total_uptime", new Long( total_uptime ) );
        //message.put( "dlstats", stats.getDownloadStats());
      }

      try{
        NetworkAdminASN current_asn = NetworkAdmin.getSingleton().getCurrentASN();

        String  as = current_asn.getAS();

        message.put( "ip_as", current_asn.getAS());

        String  asn = current_asn.getASName();

        if ( asn.length() > 64 ){

          asn = asn.substring( 0, 64 );
        }
View Full Code Here

    if ( upnp_str != null ){

      data_to_send.put( "upnp", upnp_str );
    }

      NetworkAdminASN net_asn = NetworkAdmin.getSingleton().getCurrentASN();

    String  as   = net_asn.getAS();
    String  asn = net_asn.getASName();

    if ( as.length() > 0 ){

      data_to_send.put( "as", as );
    }
View Full Code Here

        propertyChanged(
          String    property )
        {
          if ( property == NetworkAdmin.PR_AS ){
           
              NetworkAdminASN net_asn = NetworkAdmin.getSingleton().getCurrentASN();

            String  as = net_asn.getAS();
           
            if ( as.length() == 0 ){
             
              as = "default";
            }
           
            File history = new File( config_dir, "pm_" + FileUtil.convertOSSpecificChars( as, false ) + ".dat" );
           
            ping_mapper.loadHistory( history );
           
            asn = net_asn.getASName();
           
            if ( asn.length() == 0 ){
             
              asn = "Unknown";
            }
View Full Code Here

TOP

Related Classes of com.aelitis.azureus.core.networkmanager.admin.NetworkAdminASN

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.