/** * (Note that this method doesn't support @RepHandler; the implementation in * BaseDelegatingResource does.) * * @param delegate * @param rep * @return * @throws ConversionException */ @Override public SimpleObject asRepresentation(T delegate, Representation rep) throws ConversionException { if (delegate == null) throw new NullPointerException(); DelegatingResourceDescription description = getRepresentationDescription(rep); SimpleObject simple = convertDelegateToRepresentation(delegate, description); return simple; }