code: public static NbtAddress getByName( String host,
                                          int type,
                                          String scope,
                                          InetAddress svr )
                                          throws UnknownHostException {
  
          if( host == null || host.length() == 0 ) {
              return getLocalHost();
          }
          if( !Character.isDigit( host.charAt(0) )) {
              return (NbtAddress)doNameQuery( new Name( host, type, scope ), svr );
          } else {
              int IP = 0x00;
              int hitDots = 0;
              char[] data = host.toCharArray();
  
              for( int i = 0; i < data.length; i++ ) {
                  char c = data[i];
                  if( c < 48 || c > 57 ) {
                      return (NbtAddress)doNameQuery( new Name( host, type, scope ), svr );
                  }
                  int b = 0x00;
                  while( c != '.' ) {
                      if( c < 48 || c > 57 ) {
                          return (NbtAddress)doNameQuery( new Name( host, type, scope ), svr );
                      }
                      b = b * 10 + c - '0';
  
                      if( ++i >= data.length )
                          break;
  
                      c = data[i];
                  }
                  if( b > 0xFF ) {
                      return (NbtAddress)doNameQuery( new Name( host, type, scope ), svr );
                  }
                  IP = ( IP << 8 ) + b;
                  hitDots++;
              }
              if( hitDots != 4 || host.endsWith( "." )) {
                  return (NbtAddress)doNameQuery( new Name( host, type, scope ), svr );
              }
              return new NbtAddress( UNKNOWN_NAME, IP, false, B_NODE );
          }
      }
docs: /*
  The additional <code>svr</code> parameter specifies the address to
  query. This might be the address of a specific host, a name server,
  or a broadcast address.