Home Comments

enumerate derived class names of a given slice class

peterlspotpeterlspot Member Peter LauOrganization: SelfProject: Study
Wondering if there is already an API to retrieve the list of type IDs of all derived SLICE classes for a given SLICE class?

For example, suppose one have a slice:
class Food {};
class BakedFood extends Food {};
class Bread extends BakedFood{};

The list of "Food" "BakedFood" "Bread" can be returned by calling the API with type ID "food".


  • marcmarc FloridaAdministrators, ZeroC Staff Marc LaukienOrganization: ZeroC, Inc.Project: The Internet Communications Engine ZeroC Staff
    Do you mean a reflection API? No, Ice does not have this. However, at runtime, you can get a list of all IDs from a given Ice::Object instance with ice_ids().
Sign In or Register to comment.