@Override /** {@inheritDoc} */ public LayoutConsumer.Registration registerLayoutConsumer(LayoutConsumer consumer) throws IOException { Preconditions.checkState(mState.get() == State.STARTED, "TableLayoutMonitor has not been started."); mConsumers.add(consumer); consumer.update(getLayout()); return new LayoutConsumerRegistration(mConsumers, consumer); }