Mercurial Hosting > luan
comparison core/src/luan/modules/IoLuan.java @ 739:f8a7cc1fd3f6
remove Io.my_ips() not needed
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Wed, 06 Jul 2016 17:47:12 -0600 |
parents | 2486fa6490c6 |
children | 2c41f2aec92f |
comparison
equal
deleted
inserted
replaced
738:ce0d1acedc4b | 739:f8a7cc1fd3f6 |
---|---|
746 return InetAddress.getByName(domain).getHostAddress(); | 746 return InetAddress.getByName(domain).getHostAddress(); |
747 } catch(UnknownHostException e) { | 747 } catch(UnknownHostException e) { |
748 return null; | 748 return null; |
749 } | 749 } |
750 } | 750 } |
751 | 751 /* |
752 public static LuanTable my_ips() throws IOException { | 752 public static LuanTable my_ips() throws IOException { |
753 LuanTable tbl = new LuanTable(); | 753 LuanTable tbl = new LuanTable(); |
754 for( Enumeration<NetworkInterface> e1 = NetworkInterface.getNetworkInterfaces(); e1.hasMoreElements(); ) { | 754 for( Enumeration<NetworkInterface> e1 = NetworkInterface.getNetworkInterfaces(); e1.hasMoreElements(); ) { |
755 NetworkInterface ni = e1.nextElement(); | 755 NetworkInterface ni = e1.nextElement(); |
756 for( Enumeration<InetAddress> e2 = ni.getInetAddresses(); e2.hasMoreElements(); ) { | 756 for( Enumeration<InetAddress> e2 = ni.getInetAddresses(); e2.hasMoreElements(); ) { |
759 tbl.rawPut(ia.getHostAddress(),true); | 759 tbl.rawPut(ia.getHostAddress(),true); |
760 } | 760 } |
761 } | 761 } |
762 return tbl; | 762 return tbl; |
763 } | 763 } |
764 | 764 */ |
765 | 765 |
766 // files maps zip name to uri | 766 // files maps zip name to uri |
767 public static void zip(LuanState luan,String zipUri,LuanTable files) throws LuanException, IOException { | 767 public static void zip(LuanState luan,String zipUri,LuanTable files) throws LuanException, IOException { |
768 Object obj = uri(luan,zipUri,null).rawGet("java"); | 768 Object obj = uri(luan,zipUri,null).rawGet("java"); |
769 if( !(obj instanceof LuanIO) ) | 769 if( !(obj instanceof LuanIO) ) |