Package neqsim.util.validation.contracts


package neqsim.util.validation.contracts
Module contracts for AI-friendly validation.

This package provides contract interfaces that define preconditions and postconditions for NeqSim modules. AI agents can use these contracts to:

  • Validate setup before execution
  • Understand what each module requires and provides
  • Self-correct when requirements are not met

Available Contracts:

Usage Pattern:


// Before running
StreamContract contract = StreamContract.getInstance();
ValidationResult pre = contract.checkPreconditions(stream);
if (!pre.isValid()) {
  System.out.println(pre.getReport());
  // Fix issues based on remediation hints
}

stream.run();

// After running
ValidationResult post = contract.checkPostconditions(stream);
if (!post.isValid()) {
  // Handle output issues
}

Since:
1.0