public RemoteMenuController build() throws IOException {
        if(protocol == null) {
            protocol = new TagValMenuCommandProtocol();
        }
        if(executorService == null) {
            executorService = Executors.newScheduledThreadPool(2,
                    new NamedDaemonThreadFactory("udp-remote"));
        }
        UdpRemoteConnector connector = new UdpRemoteConnector(executorService, sendFreq, address, port, protocol, deviceId, sendAsDevice);
        return new RemoteMenuController(connector, menuTree, executorService, name, clock);
    }
public RemoteMenuController build ( ) throws IOException { if ( protocol == null ) { protocol = new TagValMenuCommandProtocol ( ) ; } if ( executorService == null ) { executorService = Executors . newScheduledThreadPool ( 2 , new NamedDaemonThreadFactory ( "udp-remote" ) ) ; } UdpRemoteConnector connector = new UdpRemoteConnector ( executorService , sendFreq , address , port , protocol , deviceId , sendAsDevice ) ; return new RemoteMenuController ( connector , menuTree , executorService , name , clock ) ; }
Once the above methods have been called to fill in the blanks, then call build to get
the actual instance.
@return the actual instance.