Class SeparatorContract
java.lang.Object
neqsim.util.validation.contracts.SeparatorContract
- All Implemented Interfaces:
ModuleContract<Separator>
Contract for separator equipment.
Defines requirements and guarantees for Separator implementations. AI agents can use this
contract to validate separator setup before running.
Preconditions (what the separator needs):
- At least one inlet stream connected
- Inlet stream(s) have been run
- Multi-phase fluid (gas + liquid) for meaningful separation
Postconditions (what run() provides):
- Gas outlet stream with vapor phase
- Liquid outlet stream with liquid phase(s)
- Mass/energy balance maintained
- Version:
- 1.0
- Author:
- NeqSim
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncheckPostconditions(Separator separator) Check postconditions after execution.checkPreconditions(Separator separator) Check preconditions before execution.Get the name of this contract.static SeparatorContractGet the singleton instance.Get a description of what this module provides.Get a description of what this module requires.
-
Field Details
-
INSTANCE
Singleton instance.
-
-
Constructor Details
-
SeparatorContract
private SeparatorContract()
-
-
Method Details
-
getInstance
Get the singleton instance.- Returns:
- contract instance
-
getContractName
Description copied from interface:ModuleContractGet the name of this contract.- Specified by:
getContractNamein interfaceModuleContract<Separator>- Returns:
- contract name for logging/debugging
-
checkPreconditions
Description copied from interface:ModuleContractCheck preconditions before execution.Validates that all requirements are met before running the module.
- Specified by:
checkPreconditionsin interfaceModuleContract<Separator>- Parameters:
separator- object to validate- Returns:
- validation result with any precondition failures
-
checkPostconditions
Description copied from interface:ModuleContractCheck postconditions after execution.Validates that the module produced valid output.
- Specified by:
checkPostconditionsin interfaceModuleContract<Separator>- Parameters:
separator- object to validate- Returns:
- validation result with any postcondition failures
-
getRequirementsDescription
Description copied from interface:ModuleContractGet a description of what this module requires.AI agents can use this to understand setup requirements.
- Specified by:
getRequirementsDescriptionin interfaceModuleContract<Separator>- Returns:
- human-readable requirements description
-
getProvidesDescription
Description copied from interface:ModuleContractGet a description of what this module provides.AI agents can use this to understand available outputs.
- Specified by:
getProvidesDescriptionin interfaceModuleContract<Separator>- Returns:
- human-readable outputs description
-