public String getSymbol(OWLAnonymousClass cls) {
   if (cls instanceof OWLRestriction) {
     if (cls instanceof OWLSomeValuesFrom) {
       return getOWLSomeValuesFromSymbol();
     } else if (cls instanceof OWLAllValuesFrom) {
       return getOWLAllValuesFromSymbol();
     } else if (cls instanceof OWLHasValue) {
       return getOWLHasValueSymbol();
     } else if (cls instanceof OWLCardinality) {
       return getOWLCardinalitySymbol();
     } else if (cls instanceof OWLMaxCardinality) {
       return getOWLMaxCardinalitySymbol();
     } else if (cls instanceof OWLMinCardinality) {
       return getOWLMinCardinalitySymbol();
     } else {
       throw new IllegalArgumentException("Unknown restriction type " + cls.getClass());
     }
   } else if (cls instanceof OWLIntersectionClass) {
     return getOWLIntersectionOfSymbol();
   } else if (cls instanceof OWLUnionClass) {
     return getOWLUnionOfSymbol();
   } else if (cls instanceof OWLComplementClass) {
     return getOWLComplementOfSymbol();
   } else {
     throw new IllegalArgumentException("Unexpected class type " + cls.getClass());
   }
 }
 @Override
 public Object run() throws ProtegeException {
   Collection subclasses = anonClass.getSubclasses(false);
   if (subclasses.isEmpty()) {
     OWLAnonymousClass root = anonClass.getExpressionRoot();
     if (this.equals(root)) {
       return null;
     } else {
       return root.getOwner();
     }
   } else {
     return (OWLNamedClass) subclasses.iterator().next();
   }
 }