finished NsdHelper.java