OperatorImpl template = (OperatorImpl) this.operatorTemplates.get(signature.getPredicateIndicator().toString());
//And start copying it
Structure templateSignature = new Structure(template);
Unifier un = new Unifier();
//The signature should unify with the template
if(!un.unifies(signature, templateSignature)) {
//This should not happen in a properly described domain
throw new OperatorFactoryException("Failed to unify "+templateSignature+" with operator "+templateSignature+" instantiating "+operatorSignature);
}
templateSignature.apply(un);
PropositionFactory propositionFactory = PropositionFactory.getInstance();