/** {@inheritDoc} */
 protected void doSerialize(Object value, Writer output, XmlRpcSerializer serializer)
     throws XmlRpcException, IOException {
   PackageProvider prov = (PackageProvider) value;
   SerializerHelper helper = new SerializerHelper(serializer);
   helper.add("name", prov.getName());
   helper.add("keys", prov.getKeys());
   helper.writeTo(output);
 }
  /** {@inheritDoc} */
  public void serialize(Object value, Writer output, XmlRpcSerializer builtInSerializer)
      throws XmlRpcException, IOException {

    DistChannelMap dstChannelMap = (DistChannelMap) value;
    SerializerHelper helper = new SerializerHelper(builtInSerializer);

    helper.add("os", dstChannelMap.getOs());
    helper.add("release", dstChannelMap.getRelease());
    helper.add("arch_name", dstChannelMap.getChannelArch().getName());
    helper.add("channel_label", dstChannelMap.getChannel().getLabel());

    helper.writeTo(output);
  }
  /** {@inheritDoc} */
  protected void doSerialize(Object value, Writer output, XmlRpcSerializer serializer)
      throws XmlRpcException, IOException {
    SerializerHelper helper = new SerializerHelper(serializer);
    OrgEntitlementDto dto = (OrgEntitlementDto) value;
    helper.add("label", dto.getEntitlement().getLabel());
    helper.add("name", dto.getEntitlement().getHumanReadableLabel());
    helper.add("allocated", dto.getMaxEntitlements());
    helper.add("unallocated", dto.getUpperRange() - dto.getMaxEntitlements());
    helper.add("used", dto.getCurrentEntitlements());
    helper.add("free", dto.getMaxEntitlements() - dto.getCurrentEntitlements());

    helper.writeTo(output);
  }