@Test public void requestSync() { final Connector connector = createConnector(); final TestSpyEventHandler handler = registerTestSpyEventHandler(); connector.requestSync(); verify( connector.getTransport() ).requestSync(); handler.assertEventCount( 1 ); handler.assertNextEvent( SyncRequestEvent.class, e -> assertEquals( e.getSchemaId(), connector.getSchema().getId() ) ); }
void requestSync() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy().reportSpyEvent( new SyncRequestEvent( getSchema().getId() ) ); } _transport.requestSync(); triggerMessageScheduler(); }
Connector extends ReplicantService { void requestSync() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy().reportSpyEvent( new SyncRequestEvent( getSchema().getId() ) ); } _transport.requestSync(); triggerMessageScheduler(); } }
Connector extends ReplicantService { void requestSync() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy().reportSpyEvent( new SyncRequestEvent( getSchema().getId() ) ); } _transport.requestSync(); triggerMessageScheduler(); } Connector( @Nullable final ReplicantContext context,
             @Nonnull final SystemSchema schema,
             @Nonnull final Transport transport ); }
Connector extends ReplicantService { void requestSync() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy().reportSpyEvent( new SyncRequestEvent( getSchema().getId() ) ); } _transport.requestSync(); triggerMessageScheduler(); } Connector( @Nullable final ReplicantContext context,
             @Nonnull final SystemSchema schema,
             @Nonnull final Transport transport ); @Override String toString(); }
Connector extends ReplicantService { void requestSync() { if ( Replicant.areSpiesEnabled() && getReplicantContext().getSpy().willPropagateSpyEvents() ) { getReplicantContext().getSpy().reportSpyEvent( new SyncRequestEvent( getSchema().getId() ) ); } _transport.requestSync(); triggerMessageScheduler(); } Connector( @Nullable final ReplicantContext context,
             @Nonnull final SystemSchema schema,
             @Nonnull final Transport transport ); @Override String toString();  }