@Test void doesNotAllowNullAlternateIdentifier() { CoreContext ctx = new CoreContext(mock(Core.class), 1, mock(CoreEnvironment.class), mock(Authenticator.class)); assertEquals(Optional.empty(), ctx.alternateAddress()); assertThrows(InvalidArgumentException.class, () -> ctx.alternateAddress(null)); }
public Optional<String> alternateAddress() { return alternateAddress; }
CoreContext extends AbstractContext { public Optional<String> alternateAddress() { return alternateAddress; } }
CoreContext extends AbstractContext { public Optional<String> alternateAddress() { return alternateAddress; } CoreContext(final Core core, final long id, final CoreEnvironment env, final Authenticator authenticator); }
CoreContext extends AbstractContext { public Optional<String> alternateAddress() { return alternateAddress; } CoreContext(final Core core, final long id, final CoreEnvironment env, final Authenticator authenticator); long id(); CoreEnvironment environment(); Optional<String> alternateAddress(); Authenticator authenticator(); @Stability.Internal CoreContext alternateAddress(final Optional<String> alternateAddress); Core core(); @Override void injectExportableParams(final Map<String, Object> input); }
CoreContext extends AbstractContext { public Optional<String> alternateAddress() { return alternateAddress; } CoreContext(final Core core, final long id, final CoreEnvironment env, final Authenticator authenticator); long id(); CoreEnvironment environment(); Optional<String> alternateAddress(); Authenticator authenticator(); @Stability.Internal CoreContext alternateAddress(final Optional<String> alternateAddress); Core core(); @Override void injectExportableParams(final Map<String, Object> input);  }