class ImmutablePolicyBuilder implements PolicyBuilder {

    @Override
    public Policy build() {
        final Collection<Label> allLabels = getAllLabels();

        final Collection<PolicyEntry> policyEntries = allLabels.stream()
                .map(lbl -> PoliciesModelFactory.newPolicyEntry(lbl, getFinalSubjects(lbl), getFinalResources(lbl)))
                .collect(Collectors.toList());

        return ImmutablePolicy.of(id, lifecycle, revision, modified, created, policyEntries);
    }

    private  ImmutablePolicyBuilder();

}