Is there a way to take an argument in a callable method?

后端 未结 7 1054
Happy的楠姐
Happy的楠姐 2020-12-23 16:41

I have created a piece of code which takes an IP address (from main method in another class) and then loops through a range of IP addresses pinging each one as it goes. I ha

7条回答
  •  失恋的感觉
    2020-12-23 16:56

    When you create the doPing-class (should be captial letter in class name), send in the ip-address in the constructor. Use this ip-address in the call-method.

提交回复
热议问题