Either is great, perfect for what is needed, except for the indirection and the added memory and cpu costs thereof. If ScalesXml is meant to be used in the placesthat JAXP and friends would live it should perform the best it can.
That means reducing allocations wherever possible and optimising up to the point of model damage. I think this unfortunately crosses that line but meets the aim.
Either is great, perfect for what is needed, except for the indirection and the added memory and cpu costs thereof. If ScalesXml is meant to be used in the placesthat JAXP and friends would live it should perform the best it can.
That means reducing allocations wherever possible and optimising up to the point of model damage. I think this unfortunately crosses that line but meets the aim.