@Test public void toStringWhenNamesDisabled() { ReplicantTestUtil.disableNames(); final SystemSchema systemSchema = new SystemSchema( ValueUtil.randomInt(), null, new ChannelSchema[ 0 ], new EntitySchema[ 0 ] ); assertEquals( systemSchema.toString(), "replicant.SystemSchema@" + Integer.toHexString( systemSchema.hashCode() ) ); }
@Override public String toString() { if ( Replicant.areNamesEnabled() ) { return getName(); } else { return super.toString(); } }
SystemSchema { @Override public String toString() { if ( Replicant.areNamesEnabled() ) { return getName(); } else { return super.toString(); } } }
SystemSchema { @Override public String toString() { if ( Replicant.areNamesEnabled() ) { return getName(); } else { return super.toString(); } } SystemSchema( final int id,
                       @Nullable final String name,
                       @Nonnull final ChannelSchema[] channels,
                       @Nonnull final EntitySchema[] entities ); }
SystemSchema { @Override public String toString() { if ( Replicant.areNamesEnabled() ) { return getName(); } else { return super.toString(); } } SystemSchema( final int id,
                       @Nullable final String name,
                       @Nonnull final ChannelSchema[] channels,
                       @Nonnull final EntitySchema[] entities ); int getId(); @Nonnull String getName(); int getEntityCount(); @Nonnull EntitySchema getEntity( final int typeId ); int getChannelCount(); @Nonnull ChannelSchema getChannel( final int channelId ); @Override String toString(); }
SystemSchema { @Override public String toString() { if ( Replicant.areNamesEnabled() ) { return getName(); } else { return super.toString(); } } SystemSchema( final int id,
                       @Nullable final String name,
                       @Nonnull final ChannelSchema[] channels,
                       @Nonnull final EntitySchema[] entities ); int getId(); @Nonnull String getName(); int getEntityCount(); @Nonnull EntitySchema getEntity( final int typeId ); int getChannelCount(); @Nonnull ChannelSchema getChannel( final int channelId ); @Override String toString();  }