/** * Gets the protocol with the given ID. * * @param id the protocol ID * * @return Protocol a protocol * * @throws IllegalStateException if a protocol with the ID cannot be found */ public static Protocol getProtocol(String id) throws IllegalStateException { if (id == null) { throw new IllegalArgumentException("id is null"); } Protocol protocol = (Protocol) PROTOCOLS.get(id); if (protocol == null) { protocol = lazyRegisterProtocol(id); } return protocol; }
/** * Gets the protocol with the given ID. * * @param id the protocol ID * * @return Protocol a protocol * * @throws IllegalStateException if a protocol with the ID cannot be found */ public static Protocol getProtocol(String id) throws IllegalStateException { if (id == null) { throw new IllegalArgumentException("id is null"); } Protocol protocol = (Protocol) PROTOCOLS.get(id); if (protocol == null) { protocol = lazyRegisterProtocol(id); } return protocol; }
/** * Gets the protocol with the given ID. * * @param id the protocol ID * * @return Protocol a protocol * * @throws IllegalStateException if a protocol with the ID cannot be found */ public static Protocol getProtocol(String id) throws IllegalStateException { if (id == null) { throw new IllegalArgumentException("id is null"); } Protocol protocol = (Protocol) PROTOCOLS.get(id); if (protocol == null) { protocol = lazyRegisterProtocol(id); } return protocol; }
/** * Gets the protocol with the given ID. * * @param id the protocol ID * * @return Protocol a protocol * * @throws IllegalStateException if a protocol with the ID cannot be found */ public static Protocol getProtocol(String id) throws IllegalStateException { if (id == null) { throw new IllegalArgumentException("id is null"); } Protocol protocol = (Protocol) PROTOCOLS.get(id); if (protocol == null) { protocol = lazyRegisterProtocol(id); } return protocol; }
/** * Gets the protocol with the given ID. * * @param id the protocol ID * * @return Protocol a protocol * * @throws IllegalStateException if a protocol with the ID cannot be found */ public static Protocol getProtocol(String id) throws IllegalStateException { if (id == null) { throw new IllegalArgumentException("id is null"); } Protocol protocol = (Protocol) PROTOCOLS.get(id); if (protocol == null) { protocol = lazyRegisterProtocol(id); } return protocol; }