public Collection<ChainSpecification> allChainsFlattened() {
        Resolver<ChainSpecification> resolver = new Resolver<ChainSpecification>() {
            @Override
            public ChainSpecification resolve(ComponentSpecification componentSpecification) {
                ComponentAdaptor<ChainSpecification> spec = chainSpecifications.getComponent(componentSpecification);
                return (spec==null) ? null : spec.model;
            }
        };

        Collection<ChainSpecification> chains = new ArrayList<>();
        for (ComponentAdaptor<ChainSpecification> chain : chainSpecifications.allComponents()) {
            chains.add(chain.model.flatten(resolver));
        }
        return chains;
    }
A model of how the chains and components should be created.

@author Tony Vaagenes
container-core/src/main/java/com/yahoo/component/chain/model/ChainsModel.java