- public SwitchShardBehavior(String shardName, String newState, long term) {
- this.shardName = shardName;
- this.newState = newState;
+ public SwitchShardBehavior(String shardName, RaftState newState, long term) {
+ this.shardName = Preconditions.checkNotNull(shardName);
+ this.newState = Preconditions.checkNotNull(newState);