// Only non-preference NegotiableCapability objects can be added
// to this NCS, which is ok, since these represent the capabilities
// of the client and thus are not preferences as much as they are
// hard capabilities (i.e. non-preferences)
NegotiableCapabilitySet capabilities =
new NegotiableCapabilitySet(false);
// Note that tileEncoder capabilities cannot be added since there is
// no way to differentiate between a encoding and a decoding capability
// within an NCS, and since the client should only be expected to
// decode, this should be ok.
Iterator it;
for (int i=0; i<descriptorNames.length; i++) {
it = registry.getFactoryIterator(modeName, descriptorNames[i]);
for (; it.hasNext(); ) {
tdf = (TileDecoderFactory)it.next();
capabilities.add(tdf.getDecodeCapability());
}
}
return capabilities;
}