/// <summary> /// Returns true if the <paramref name="specialized"/> class /// can substitute its parent in an associatoin. /// </summary> /// <param name="specialized"> specialized class</param> /// <returns>true if the <paramref name="specialized"/> class /// can substitute its parent in an associatoin</returns> public static bool CanSubstituteInAssociation(this PSMClass specialized) { /* * jeste jedna takova slozita podminka: pokud ma abstract PSM class prirazeny * element label, tak nebude odvozena odpovidajici element declaration. * vyjimkou je, pokud je od ni podedena nejaka non-abstract PSM class bez element labelu */ if (!specialized.IsAbstract) { return(true); } else { return(specialized.NonAbstractWithoutLabelRecursive()); } }