private List<ObjectAssociation> asAssociations(final OrderSet orderSet) {
    if (orderSet == null) {
      return null;
    }
    final List<ObjectAssociation> associations = Lists.newArrayList();
    for (final Object element : orderSet) {
      if (element instanceof FacetedMethod) {
        final FacetedMethod facetMethod = (FacetedMethod) element;
        if (facetMethod.getFeatureType().isCollection()) {
          associations.add(createCollection(facetMethod));
        } else if (facetMethod.getFeatureType().isProperty()) {
          associations.add(createProperty(facetMethod));
        }
      } else if (element instanceof OrderSet) {
        // Not supported at present
      } else {
        throw new UnknownTypeException(element);
      }
    }

    return associations;
  }
 private List<ObjectAction> asObjectActions(final OrderSet orderSet) {
   if (orderSet == null) {
     return null;
   }
   final List<ObjectAction> actions = Lists.newArrayList();
   for (final Object element : orderSet) {
     if (element instanceof FacetedMethod) {
       final FacetedMethod facetedMethod = (FacetedMethod) element;
       if (facetedMethod.getFeatureType().isAction()) {
         actions.add(createAction(facetedMethod));
       }
     } else if (element instanceof OrderSet) {
       final OrderSet set = ((OrderSet) element);
       actions.add(createObjectActionSet(set));
     } else {
       throw new UnknownTypeException(element);
     }
   }
   return actions;
 }