Kafka.Client.Request.ProducerRequest.IsValid C# (CSharp) Method

IsValid() public method

Determines if the request has valid settings.
public IsValid ( ) : bool
return bool
        public override bool IsValid()
        {
            return !string.IsNullOrWhiteSpace(Topic) && Messages != null && Messages.Count > 0;
        }

Usage Example

示例#1
0
 public void IsValidFalseNoTopic()
 {
     ProducerRequest request = new ProducerRequest(null, 0, null);
     Assert.IsFalse(request.IsValid());
 }
All Usage Examples Of Kafka.Client.Request.ProducerRequest::IsValid